rudolph-miller / jonathan

JSON encoder and decoder.
http://rudolph-miller.github.io/jonathan/overview.html
164 stars 24 forks source link

Add method for simple-string #41

Closed fisxoj closed 8 years ago

fisxoj commented 8 years ago

Fixes Rudolph-Miller/jonathan#40 by adding a method on simple-string and changing string's method to use a slower way, but not error.

rudolph-miller commented 8 years ago

LGTM! :octocat:

rudolph-miller commented 8 years ago

Thanks! :)

fisxoj commented 8 years ago

That was impressive turn around time! Thank you!

coveralls commented 8 years ago

Coverage Status

Coverage remained the same at 71.667% when pulling 22455b3634dd80f13d381f382f344d812a23379b on fisxoj:strings into 4a371f1c6e2b7cb5da434a4acc5246e98f4aac77 on Rudolph-Miller:master.

fukamachi commented 8 years ago

This change causes an error with ECL, like:

In method definition for %TO-JSON, found an invalid specializer (SIMPLE-STRING).

SIMPLE-STRING is a type, not a class, so cannot specify as a specializer.

Instead of adding a new method, just (coerce string 'simple-string) in the method should work.

rudolph-miller commented 8 years ago

Fixed. https://github.com/Rudolph-Miller/jonathan/commit/e72e4d744c1f5bf4dcdf23ca9d52e7067311f247