Advertisement
Guest User

Untitled

a guest
Oct 24th, 2014
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. req.on('end', function onEnd() {
  2. console.log('winning');
  3. });
  4.  
  5. req.on('end', function() {
  6. console.log('losing');
  7. });
  8.  
  9. function someName() { someStatements(); }
  10.  
  11. function someName() { someStatements(); }
  12.  
  13. setTimeout(function someName() { someStatements(); }, 500);
  14.  
  15. var f = function g() {
  16. return 1;
  17. };
  18. if (false) {
  19. f = function g(){
  20. return 2;
  21. };
  22. }
  23. g(); // 2
  24.  
  25. req.on('end', function onEnd() {
  26. console.log(onEnd); //function body
  27. });
  28. console.log(onEnd); //ReferenceError: onEnd is not defined
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement