{"action":"created","issue":{"url":"https://api.github.com/repos/less/less.js/issues/2378","labels_url":"https://api.github.com/repos/less/less.js/issues/2378/labels{/name}","comments_url":"https://api.github.com/repos/less/less.js/issues/2378/comments","events_url":"https://api.github.com/repos/less/less.js/issues/2378/events","html_url":"https://github.com/less/less.js/pull/2378","id":53939072,"number":2378,"title":"variable variables with named colors error","user":{"login":"bassjobsen","id":954055,"avatar_url":"https://avatars.githubusercontent.com/u/954055?v=3","gravatar_id":"","url":"https://api.github.com/users/bassjobsen","html_url":"https://github.com/bassjobsen","followers_url":"https://api.github.com/users/bassjobsen/followers","following_url":"https://api.github.com/users/bassjobsen/following{/other_user}","gists_url":"https://api.github.com/users/bassjobsen/gists{/gist_id}","starred_url":"https://api.github.com/users/bassjobsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bassjobsen/subscriptions","organizations_url":"https://api.github.com/users/bassjobsen/orgs","repos_url":"https://api.github.com/users/bassjobsen/repos","events_url":"https://api.github.com/users/bassjobsen/events{/privacy}","received_events_url":"https://api.github.com/users/bassjobsen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-10T01:45:18Z","updated_at":"2015-01-11T01:56:26Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/less/less.js/pulls/2378","html_url":"https://github.com/less/less.js/pull/2378","diff_url":"https://github.com/less/less.js/pull/2378.diff","patch_url":"https://github.com/less/less.js/pull/2378.patch"},"body":"I not sure if this PR make sense at all. But i found that:\r\n\r\n```css\r\n@color: blue;\r\n@blue: yellow;\r\ns{\r\np: @@color;\r\n}\r\n```\r\n\r\nthrows: `NameError: variable @undefined is undefined in`, the error makes sense cause a color can not be the name of a variable, but the error message does not.\r\nInstead of trowing an error, the problems seems also to fix with `v.value.value = v.value.keyword;`.\r\n\r\nPossible everybody knows already have to use only strings  or only the documentation at http://lesscss.org/features/#variables-feature-variable-names should be updated for that."},"comment":{"url":"https://api.github.com/repos/less/less.js/issues/comments/69480333","html_url":"https://github.com/less/less.js/pull/2378#issuecomment-69480333","issue_url":"https://api.github.com/repos/less/less.js/issues/2378","id":69480333,"user":{"login":"seven-phases-max","id":5304376,"avatar_url":"https://avatars.githubusercontent.com/u/5304376?v=3","gravatar_id":"","url":"https://api.github.com/users/seven-phases-max","html_url":"https://github.com/seven-phases-max","followers_url":"https://api.github.com/users/seven-phases-max/followers","following_url":"https://api.github.com/users/seven-phases-max/following{/other_user}","gists_url":"https://api.github.com/users/seven-phases-max/gists{/gist_id}","starred_url":"https://api.github.com/users/seven-phases-max/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seven-phases-max/subscriptions","organizations_url":"https://api.github.com/users/seven-phases-max/orgs","repos_url":"https://api.github.com/users/seven-phases-max/repos","events_url":"https://api.github.com/users/seven-phases-max/events{/privacy}","received_events_url":"https://api.github.com/users/seven-phases-max/received_events","type":"User","site_admin":false},"created_at":"2015-01-11T01:56:26Z","updated_at":"2015-01-11T01:56:26Z","body":"I have another fix for this (I guess I simply forgot about it). See https://github.com/less/less.js/pull/1604#issuecomment-37556397. And the corresponding PR.\r\n\r\n>Possible everybody knows already have to use only strings\r\n\r\nNot nesessary. It's more like an unspecified stuff. \r\nThis code works fine:\r\n```\r\n@1: bar;\r\n@ref: 1;\r\n\r\ndiv {\r\n    foo: @@ref;\r\n}\r\n```\r\nWhile this does not:\r\n```\r\n@1px: bar;\r\n@ref: 1px;\r\n\r\ndiv {\r\n    foo: @@ref;\r\n}\r\n```\r\n---\r\nEither way I think is all right to allow color keywords to be used as variable name references (after all you don't have to know that `rye` is evaluated as an ordinary keyword but `wheat` as a color object and why the heck they work differently :).\r\nI have another fix for this (I guess I simply forgot about it). See https://github.com/less/less.js/pull/1604#issuecomment-37556397. And [the corresponding PR](https://github.com/less/less.js/pull/2380).\r\n\r\n>Possible everybody knows already have to use only strings\r\n\r\nNot nesessary. It's more like an unspecified stuff. \r\nThis code works fine:\r\n```\r\n@1: bar;\r\n@ref: 1;\r\n\r\ndiv {\r\n    foo: @@ref;\r\n}\r\n```\r\nWhile this does not:\r\n```\r\n@1px: bar;\r\n@ref: 1px;\r\n\r\ndiv {\r\n    foo: @@ref;\r\n}\r\n```\r\n---\r\nEither way I think is all right to allow color keywords to be used as variable name references (after all you don't have to know that `rye` is evaluated as an ordinary keyword but `wheat` as a color object and why the heck they work differently :)."}}