Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Talk about ends, rather than means, in macro tutorial introduction. #3823

Merged
merged 1 commit into from
Oct 21, 2012
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions doc/tutorial-macros.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

# Introduction

Functions are the primary tool that programmers can use to build
abstractions. Sometimes, though, programmers want to abstract over
compile-time, syntactic structures rather than runtime values. For example,
the following two code fragments both pattern-match on their input and return
early in one case, doing nothing otherwise:
Functions are the primary tool that programmers can use to build abstractions.
Sometimes, however, programmers want to perform abstractions over things that are not
runtime values. Macros provide a syntactic abstraction. For an example of how this
can be useful, consider the following two code fragments, which both pattern-match
on their input and return early in one case, and do nothing otherwise:

~~~~
# enum t { special_a(uint), special_b(uint) };
Expand Down