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

Typo in exercise 15.34 / 15.36 #803

Open
RedactedContributor opened this issue Jun 30, 2021 · 0 comments
Open

Typo in exercise 15.34 / 15.36 #803

RedactedContributor opened this issue Jun 30, 2021 · 0 comments

Comments

@RedactedContributor
Copy link

RedactedContributor commented Jun 30, 2021

README for exercise 15.34:

For the expression built in Figure 15.3 (p. 638):
Query q = Query("fiery") & Query("bird") | Query("wind");

(a) List the constructors executed in processing that expression.

5. Query::Query(std::shared_ptr<Query_base> query) 2times
8. Query::Query(std::shared_ptr<Query_base> query) 2times

claims that the Query::Query(std::shared_ptr<Query_base> query) constructor is called multiple times for the expression, but the answer for exercise 15.36 two sections down contradicts it.

Query q = Query("fiery") & Query("bird") | Query("wind");
[ ... ]
AndQuery::AndQuery()
Query::Query(std::shared_ptr<Query_base> query)
OrQuery::OrQuery
Query::Query(std::shared_ptr<Query_base> query)
[ ... ]

I did the exercise myself and the output was similar to the above.

@RedactedContributor RedactedContributor changed the title Small typo in exercise 15.34 / 15.36 Typo in exercise 15.34 / 15.36 Jun 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant