summaryrefslogtreecommitdiff
path: root/tests/lexers/cfc/example2.txt
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lexers/cfc/example2.txt')
-rw-r--r--tests/lexers/cfc/example2.txt179
1 files changed, 179 insertions, 0 deletions
diff --git a/tests/lexers/cfc/example2.txt b/tests/lexers/cfc/example2.txt
new file mode 100644
index 00000000..a9405db8
--- /dev/null
+++ b/tests/lexers/cfc/example2.txt
@@ -0,0 +1,179 @@
+---input---
+<cfcomponent>
+
+ <cffunction name="init" access="public" returntype="any">
+ <cfargument name="arg1" type="any" required="true">
+ <cfset this.myVariable = arguments.arg1>
+
+ <cfreturn this>
+ </cffunction>
+
+ <cffunction name="testFunc" access="private" returntype="void">
+ <cfargument name="arg1" type="any" required="false">
+
+ <cfif structKeyExists(arguments, "arg1")>
+ <cfset writeoutput("Argument exists")>
+ </cfif>
+ </cffunction>
+
+</cfcomponent>
+
+---tokens---
+'<' Operator
+'cfcomponent' Name.Variable
+'>' Operator
+'\n\t\n\t' Text
+'<' Operator
+'cffunction' Name.Variable
+' ' Text
+'name' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'init' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'access' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'public' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'returntype' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'any' Literal.String.Double
+'"' Literal.String.Double
+'>' Operator
+'\n\t\t' Text
+'<' Operator
+'cfargument' Name.Variable
+' ' Text
+'name' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'arg1' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'type' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'any' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'required' Keyword
+'=' Operator
+'"' Literal.String.Double
+'true' Literal.String.Double
+'"' Literal.String.Double
+'>' Operator
+'\n\t\t' Text
+'<' Operator
+'cfset' Name.Variable
+' ' Text
+'this' Name.Constant
+'.' Punctuation
+'myVariable' Name.Variable
+' ' Text
+'=' Operator
+' ' Text
+'arguments' Name.Constant
+'.' Punctuation
+'arg1' Name.Variable
+'>' Operator
+'\n\n\t\t' Text
+'<' Operator
+'cfreturn' Name.Variable
+' ' Text
+'this' Name.Constant
+'>' Operator
+'\n\t' Text
+'<' Operator
+'/' Operator
+'cffunction' Name.Variable
+'>' Operator
+'\n\n\t' Text
+'<' Operator
+'cffunction' Name.Variable
+' ' Text
+'name' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'testFunc' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'access' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'private' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'returntype' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'void' Literal.String.Double
+'"' Literal.String.Double
+'>' Operator
+'\n\t\t' Text
+'<' Operator
+'cfargument' Name.Variable
+' ' Text
+'name' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'arg1' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'type' Name.Variable
+'=' Operator
+'"' Literal.String.Double
+'any' Literal.String.Double
+'"' Literal.String.Double
+' ' Text
+'required' Keyword
+'=' Operator
+'"' Literal.String.Double
+'false' Literal.String.Double
+'"' Literal.String.Double
+'>' Operator
+'\n\t\t\n\t\t' Text
+'<' Operator
+'cfif' Name.Variable
+' ' Text
+'structKeyExists' Name.Function
+'(' Punctuation
+'arguments' Name.Constant
+',' Punctuation
+' ' Text
+'"' Literal.String.Double
+'arg1' Literal.String.Double
+'"' Literal.String.Double
+')' Punctuation
+'>' Operator
+'\n\t\t\t' Text
+'<' Operator
+'cfset' Name.Variable
+' ' Text
+'writeoutput' Name.Function
+'(' Punctuation
+'"' Literal.String.Double
+'Argument exists' Literal.String.Double
+'"' Literal.String.Double
+')' Punctuation
+'>' Operator
+'\n\t\t' Text
+'<' Operator
+'/' Operator
+'cfif' Name.Variable
+'>' Operator
+'\n\t' Text
+'<' Operator
+'/' Operator
+'cffunction' Name.Variable
+'>' Operator
+'\n\t\n' Text
+
+'<' Operator
+'/' Operator
+'cfcomponent' Name.Variable
+'>' Operator
+'\n' Text