9 Matching Annotations
  1. Dec 2022
    1. The deferred call's arguments are evaluated immediately, but the function call is not executed until the surrounding function returns.

      延迟调用的参数会立即求值,但直到周围函数返回时才会执行函数调用。

      ``` func main() { defer fmt.Println(time.Now()) time.Sleep(time.Second * 2) fmt.Println(time.Now()) }

      ```

  2. Feb 2021
  3. Oct 2020
    1. This Boolean attribute is set to indicate to a browser that the script is meant to be executed after the document has been parsed, but before firing DOMContentLoaded.
    2. The defer attribute has no effect on module scripts — they defer by default.
  4. Mar 2020
    1. The last responsible moment mindset can at times lull me (erroneously) into thinking that I’ll always have time to change my mind if I need to. I’m ever the optimist. Yet in order to work well with others and to produce habitable software I sometimes need a little more forethought. And so, I think I operate more effectively if I make decisions at the “most responsible moment” instead of the “last responsible moment”. I’m not a good enough of a designer (or maybe I am too much of an optimist) to know when the last responsible moment is. Just having a last-responsible moment mindset leaves me open to making late decisions. I’m sure this is not what Mary and Tom intended at all.
    2. decisions that initially appear to be localized (and not to impact others who are working in other areas) can and frequently do have ripple affects outside their initially perceived sphere of influence
    3. I am not known as someone who plans things far out in advance. As a consequence I rarely use frequent flyer miles because I don’t anticipate vacation plans far enough in advance.
    4. Deciding too late is dangerous, but deciding too early in the rapidly changing world of software development is arguably even more dangerous. Let the principle of Last Responsible Moment be your guide
    5. delay commitment until the last responsible moment, that is, the moment at which failing to make a decision eliminates an important alternative