Git Product home page Git Product logo

Comments (8)

franciscovg avatar franciscovg commented on September 29, 2024

call, set, unset and return cause Varnish to perform specific actions, therefore they are not keywords, but instructions. I agree that they are not functions.

Text updated in commit c4d2b8f

from varnish-book.

fgsch avatar fgsch commented on September 29, 2024

This is what is called keywords in any other languages.

IMO there is no need to create another naming.

from varnish-book.

franciscovg avatar franciscovg commented on September 29, 2024

I checked the definition of instruction in book The Art of Computer Programming by Knuth D. I think the word keyword can be confusing because it can represent commands, parameters or reserved names.

from varnish-book.

fgsch avatar fgsch commented on September 29, 2024

That's actually the case. You cannot use those in parameters and you cannot create variables called after any of them.

from varnish-book.

franciscovg avatar franciscovg commented on September 29, 2024

In the book we say that action in return(action) is a keyword. I think it is important to differentiate their type. Otherwise, we are saying that the keyword return has the keyword action as argument.

from varnish-book.

fgsch avatar fgsch commented on September 29, 2024

Why? actions are keywords as well. return is probably the most universal keyword of all.

You are creating an issue where there is none.

from varnish-book.

dridi avatar dridi commented on September 29, 2024

I agree with @fgsch, keyword is a good fit that probably anyone would understand in both contexts. By the way, a keyword doesn't have to be a reserved word too, it's just the case most of the time.

from varnish-book.

franciscovg avatar franciscovg commented on September 29, 2024

Ok, I see that keyword is the appropriate term here. Text updated in 22a64af. Thanks for the discussion.

from varnish-book.

Related Issues (20)

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.