Revision 27878 (by Whiteknight, 2008/05/28 14:44:03) [languages] updating all languages except Tcl and Perl6 to use ".namespace []" as per rt#48549. all tests that were passing are still passing.
# $Id: var_or_function.pir 27878 2008-05-28 14:44:03Z Whiteknight $

=head1

var_or_function.pir - Distinguish variable access and function call

=cut

.namespace []

.sub 'var_or_function'
    .param pmc name
    .local pmc result
    $I0 = isa name, 'Sub'
    if $I0 goto funcall
    .return (name)
    funcall:
    result = name()
    .return (result)
.end


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