scaledn icon indicating copy to clipboard operation
scaledn copied to clipboard

refactored symbols/keywords with named/namespace

Open mandubian opened this issue 10 years ago • 4 comments

mandubian avatar Dec 27 '14 16:12 mandubian

@ahoy-jon what do you think about this PR?

mandubian avatar Dec 27 '14 16:12 mandubian

Arg, I have a issue now with how symbols/keyworks/tags are made in Clojure : :a/b/c, :/a/b/c, a/b/c, /a/b/c seems to be valid in Clojure, maybe the Named abstraction with a namespace is not good enough !

ahoy-jon avatar Dec 27 '14 22:12 ahoy-jon

In EDN format, the namespace isn't specified as having multiple subparts. The namespace can contain dot chars but apparently no /. Clojure is a superset of EDN. In datalog, the namespace is simple too. Why do you need those complex namespaces? Le 27 déc. 2014 23:24, "Jonathan Winandy" [email protected] a écrit :

Arg, I have a issue now with how symbols/keyworks/tags are made in Clojure : :a/b/c, :/a/b/c, a/b/c, /a/b/c seems to be valid in Clojure, maybe the Named abstraction with a namespace is not good enough !

— Reply to this email directly or view it on GitHub https://github.com/mandubian/scaledn/pull/7#issuecomment-68192110.

mandubian avatar Dec 27 '14 22:12 mandubian

I rechecked the spec, and that's ok ! (I don't need such complex namespace, I wanted to see If they were allowed).

As for Named, how can the String used be checked ? like respecting : [a-zA-Z](:?[a-zA-Z.*+!\-_?$%&=<>#0-9])* or ([a-zA-Z]|([.+\-]:?[a-zA-Z.*+!\-_?$%&=<>#]))(:?[a-zA-Z.*+!\-_?$%&=<>#0-9])*

(: have a special treatment here I don't quite understand, a: is not a valid symbol in Clojure, but a:a is. )

Else, I can't see of anything !

ahoy-jon avatar Dec 28 '14 00:12 ahoy-jon