About some sentence problems in Date.js

Date.getParseFunction = function (fx) {
    var fn = Date.Grammar.formats(fx);
    return function (s) {
        var r = null;
        try {
            r = fn.call({}, s);
        } catch (e) {
            return null;
        }
        return ((r[1].length === 0) ? r[0] : null);
    };
};
Date.parseExact = function (s, fx) {
    return Date.getParseFunction(fx)(s);
};

excuse me:

1.function (s, fx){} //sfx
2.fn.call({}, s);//
3.return ((r[1].length === 0) ? r[0] : null);//   

I would also like to trouble you for an answer. Thank you very much

Jun.29,2021

is there any great god who can answer


  • function (s, fx) {} / / fx, s is getParseFunction and the parameters it needs to return anonymous functions
  • fn.call ({}, s) / / indicates that this points to this empty object in fn , and s is the parameter required by fn
  • .
  • if you don't understand this, you must understand
    if((r[1].length === 0)) {
      return r[0]
    }
    
    return null
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e5a3d5-44adc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e5a3d5-44adc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?