Git Product home page Git Product logo

zzzjson's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

zzzjson's Issues

Unused temp values in the zj_strToLong et al

There is an inconsistency in the implementation of the string to number functions.
Only the zj_strToInt function uses the s variable in the string conversion.
The other functions use the input argument.

static inline int zj_strToInt(const char *str, zj_Size len) {
  char s[128] = {0};
  memcpy(s, str, len);
  return atoi(s);
}
static inline long zj_strToLong(const char *str, zj_Size len) {
  char s[128] = {0};
  memcpy(s, str, len);
  return atol(str);
}
static inline long long zj_strToLongLong(const char *str, zj_Size len) {
  char s[128] = {0};
  memcpy(s, str, len);
  return atoll(str);
}
static inline double zj_strToDouble(const char *str, zj_Size len) {
  char s[128] = {0};
  memcpy(s, str, len);
  return atof(str);
}

[Not an issue] Can I know what algorithm is being used here?

I didn't really understand how you parsed the unicode in the following line of code:
zj_consumeStr function.

Can you please explain this part? What are the magic numbers; 0xDC00, 0xDFFF, 0xD800``0xDBFF that are being used here and why these checks?

I am using this library as a reference to build a lexer for another parser. Help would be appreciated

License file?

Hi,

This looks great, but I'm not sure if/how am I allowed to use zzzjson.

Could you perhaps add a license?

Thanks,
Eli

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.