Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Create type-safe Collections in Java... with Perl

by John M. Dlugosz (Monsignor)
on Jun 14, 2001 at 23:27 UTC ( [id://88586]=note: print w/replies, xml ) Need Help??


in reply to Create type-safe Collections in Java... with Perl

Many years ago, before C++ templates were implemented, I wrote a preprocessor for that, so I could play with them ahead of time. It didn't look anything like modern template syntax—I used the @ symbol, which is not used anywhere else in C++, for stuff that my program manipulated. It wasn't as limited as modern templates, either, as it was a more general-purpose macro system.

I see you're not using a grammar parser at all, but just looking for a pattern on each line. Won't that be very difficult to do "right" for quotes, comments, etc.?

Why does it look only for known template types? Why not first recognise the template syntax, then check to see if that template is known (such as in a like-named file)?

—John

  • Comment on Re: Create type-safe Collections in Java... with Perl

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://88586]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others exploiting the Monastery: (6)
As of 2024-04-23 13:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found