Exemple #1
0
        static LispReader()
        {
            _macros['"'] = new StringReader();
            _macros[';'] = new CommentReader();
            _macros['\''] = new WrappingReader(QUOTE);
            _macros['@'] = new WrappingReader(DEREF);//new DerefReader();
            _macros['^'] = new WrappingReader(META);
            _macros['`'] = new SyntaxQuoteReader();
            _macros['~'] = new UnquoteReader();
            _macros['('] = new ListReader();
            _macros[')'] = new UnmatchedDelimiterReader();
            _macros['['] = new VectorReader();
            _macros[']'] = new UnmatchedDelimiterReader();
            _macros['{'] = new MapReader();
            _macros['}'] = new UnmatchedDelimiterReader();
            ////	macros['|'] = new ArgVectorReader();
            _macros['\\'] = new CharacterReader();
            _macros['%'] = new ArgReader();
            _macros['#'] = new DispatchReader();

            _dispatchMacros['^'] = new MetaReader();
            _dispatchMacros['\''] = new VarReader();
            _dispatchMacros['"'] = new RegexReader();
            _dispatchMacros['('] = new FnReader();
            _dispatchMacros['{'] = new SetReader();
            _dispatchMacros['='] = new EvalReader();
            _dispatchMacros['!'] = new CommentReader();
            _dispatchMacros['<'] = new UnreadableReader();
            _dispatchMacros['_'] = new DiscardReader();
        }
Exemple #2
0
        static LispReader()
        {
            _macros['"']  = new StringReader();
            _macros[';']  = new CommentReader();
            _macros['\''] = new WrappingReader(QUOTE);
            _macros['@']  = new WrappingReader(DEREF);//new DerefReader();
            _macros['^']  = new WrappingReader(META);
            _macros['`']  = new SyntaxQuoteReader();
            _macros['~']  = new UnquoteReader();
            _macros['(']  = new ListReader();
            _macros[')']  = new UnmatchedDelimiterReader();
            _macros['[']  = new VectorReader();
            _macros[']']  = new UnmatchedDelimiterReader();
            _macros['{']  = new MapReader();
            _macros['}']  = new UnmatchedDelimiterReader();
            ////	macros['|'] = new ArgVectorReader();
            _macros['\\'] = new CharacterReader();
            _macros['%']  = new ArgReader();
            _macros['#']  = new DispatchReader();


            _dispatchMacros['^']  = new MetaReader();
            _dispatchMacros['\''] = new VarReader();
            _dispatchMacros['"']  = new RegexReader();
            _dispatchMacros['(']  = new FnReader();
            _dispatchMacros['{']  = new SetReader();
            _dispatchMacros['=']  = new EvalReader();
            _dispatchMacros['!']  = new CommentReader();
            _dispatchMacros['<']  = new UnreadableReader();
            _dispatchMacros['_']  = new DiscardReader();
        }