代码搜索结果

找到约 10,000 项符合 G 的代码

xml.g

/** XML parser by Oliver Zeigermann October 10, 2005 */ lexer grammar XML; options { language = Python; } @header { import sys } DOCUMENT : XMLDECL? WS? DOCTYPE? WS? ELEMENT WS? ; fra

simplec.g

grammar SimpleC; options { language = Python; } program : declaration+ ; /** In this rule, the functionHeader left prefix on the last two * alternatives is not LL(k) for a fixed k.

t.g

grammar T; options { language=Python; } program : method ; method /* name is visible to any rule called by method directly or indirectly. * There is also a stack of these names, one slot for

t.g

/** Convert the simple input to be java code; wrap in a class, * convert method with "public void", add decls. This shows how to insert * extra text into a stream of tokens and how to replace a t

python.g

/* [The 'BSD licence'] Copyright (c) 2004 Terence Parr and Loring Craymer All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted prov

simplecwalker.g

tree grammar SimpleCWalker; options { language=Python; tokenVocab=SimpleC; ASTLabelType=CommonTree; } program : declaration+ ; declaration : variable | ^(FUNC_DECL

simplec.g

grammar SimpleC; options { language=Python; output=AST; } tokens { VAR_DEF; ARG_DEF; FUNC_HDR; FUNC_DECL; FUNC_DEF; BLOCK; } program : declaration+ ; decla

java.g

/** A Java 1.5 grammar for ANTLR v3 derived from the spec * * This is a very close representation of the spec; the changes * are comestic (remove left recursion) and also fixes (the spec * isn'

actiontranslator.g

/* [The "BSD licence"] Copyright (c) 2005-2006 Terence Parr All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the

codegen.g

header { /* [The "BSD licence"] Copyright (c) 2005-2006 Terence Parr All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided