nilaway ã©ããªãã®ï¼ nil ãããã¯ã«ããã©ã³ã¿ã¤ã ã¨ã©ã¼ã«ãªãç®æãææãã¦ãããéç解æãã¼ã« ã¹ã¿ã³ãã¢ãã³ã§åããgolangci-lintã§ä½¿ç¨ããã«ã¯ã«ã¹ã¿ãã¤ãºãå¿ è¦ã å è¡æè¡ããã¼ã«ã¨æ¯ã¹ã¦ã©ãããããï¼ æ¨æºããã±ã¼ã¸ã«å梱ããã¦ããnilness[1]ã§ã¯ãã§ãã¯ã§ããªãnil ãããã¯ã¨ãªãããç®æãææãã é¢æ°ãããã±ã¼ã¸ã®å¢çãè·¨ãã§nilããã¼ã追跡 nil ã¤ã³ã¿ã¼ãã§ã¼ã¹å¤ãå ±å ä¾ãã°ä»¥ä¸ã®ã³ã¼ãã§ã¯ãnilnessã¯ã¨ã©ã¼ãå ±åãã¦ãããªãããnilawayã¯nilãããã¯ãå ±åãã¦ãããã var p *P if someCondition { p = &P{} } print(p.f) // nilness reports NO error here, but nilaway does. æè¡ã®ãã¢ã¯ã©ãï¼ Our main idea
{{#tags}}- {{label}}
{{/tags}}