Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CFLint reporting a column that doesn't exist #326

Closed
ryaneberly opened this issue Jul 1, 2017 · 0 comments
Closed

CFLint reporting a column that doesn't exist #326

ryaneberly opened this issue Jul 1, 2017 · 0 comments
Assignees

Comments

@ryaneberly
Copy link
Contributor

mtbrown - line number is most important, but column is useful for IDE integration
I'm messing with Atom's linter and it's breaking when it's larger than the line length


<cfset variables.list1 = "123,456,789">
					<cfset variables.list2 = "abc,def,ghi">
					<cfset variables.string1 = "0123456789">
					<cfset variables.string2 = "abcdefghi">

					<cfif (listFind(variables.list1, left(variables.string1, 3), ",") && listFind(variables.list1, left(variables.string2, 3), ","))
								|| (listFind(variables.list2, left(variables.string1, 3), ",") && listFind(variables.list2, left(variables.string2, 3), ","))
					>
						Test
					</cfif>
{
  "severity" : "WARNING",
  "id" : "GLOBAL_LITERAL_VALUE_USED_TOO_OFTEN",
  "message" : "GLOBAL_LITERAL_VALUE_USED_TOO_OFTEN",
  "category" : "CFLINT",
  "abbrev" : "GL",
  "locations" : [ {
    "file" : "C:\\Users\\mtbro_000\\Downloads\\CFLint\\.\\test.cfm",
    "fileName" : "test.cfm",
    "function" : "",
    "column" : "135",
    "line" : "7",
    "message" : "Literal , occurs several times in one or more files. Consider giving it a name and not hard coding values.",
    "variable" : ",",
    "expression" : "','"
  }
@ryaneberly ryaneberly self-assigned this Jul 1, 2017
ryaneberly added a commit that referenced this issue Jul 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant