Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 1e007a96761035f261351a68e7601417 > files > 685

parrot-docs-3.6.0-2.fc15.noarch.rpm

# Copyright (C) 2005-2009, Parrot Foundation.

=head1 NAME

hello.pasm - Hello World

=head1 DESCRIPTION

This is also used in the top Makefile,
for showing how to create an executable from PASM.

=cut

.pcc_sub :main main:

    # Get @ARGV as a ResizableStringArray
    get_params "0", P0

    # Discard the program name
    shift S0, P0

    # Look for additional args
    if P0, FOUND_EXTRA_ARG
        print "Hello World\n"
        end

FOUND_EXTRA_ARG:
    shift S1, P0
    print "Hello "
    print S1
    print "\n"
    end

# Local Variables:
#   mode: pir
#   fill-column: 100
# End:
# vim: expandtab shiftwidth=4 ft=pir: