diff --git a/base/cplusplus/test/inputs/json/misc/00c36.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/00c36.json/default/quicktype.hpp
index 8097a1c..7cdf88f 100644
--- a/base/cplusplus/test/inputs/json/misc/00c36.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/00c36.json/default/quicktype.hpp
@@ -235,9 +235,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, FluffyTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pages") != j.end() && !j.at("pages").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pages(j.at("pages").get<int64_t>());
         x.set_per_page(j.at("per_page").get<std::string>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/010b1.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/010b1.json/default/quicktype.hpp
index d1fb096..0186ce1 100644
--- a/base/cplusplus/test/inputs/json/misc/010b1.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/010b1.json/default/quicktype.hpp
@@ -84,11 +84,16 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_country(j.at("country").get<Country>());
+        if (j.find("females") != j.end() && !j.at("females").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_females(j.at("females").get<int64_t>());
+        if (j.find("males") != j.end() && !j.at("males").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_males(j.at("males").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/016af.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/016af.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/016af.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/016af.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/09f54.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/09f54.json/default/quicktype.hpp
index 524bc15..caa9af8 100644
--- a/base/cplusplus/test/inputs/json/misc/09f54.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/09f54.json/default/quicktype.hpp
@@ -124,6 +124,7 @@ namespace quicktype {
     inline void from_json(const json & j, Description& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_base_period(j.at("base_period").get<std::string>());
+        if (j.find("missing") != j.end() && !j.at("missing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_missing(j.at("missing").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_units(j.at("units").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/0a358.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/0a358.json/default/quicktype.hpp
index c78d86e..f966af8 100644
--- a/base/cplusplus/test/inputs/json/misc/0a358.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/0a358.json/default/quicktype.hpp
@@ -150,6 +150,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_code(j.at("code").get<std::string>());
         x.set_created_at(j.at("created_at").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_updated_at(j.at("updated_at").get<std::string>());
@@ -168,10 +169,13 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_facets(j.at("facets").get<Facets>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(j.at("previous").get<bool>());
         x.set_results(j.at("results").get<std::vector<Result>>());
diff --git a/base/cplusplus/test/inputs/json/misc/0a91a.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/0a91a.json/default/quicktype.hpp
index 995ea32..9f7d8ba 100644
--- a/base/cplusplus/test/inputs/json/misc/0a91a.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/0a91a.json/default/quicktype.hpp
@@ -1140,6 +1140,7 @@ namespace quicktype {
         x.set_avatar_url(j.at("avatar_url").get<std::string>());
         x.set_display_login(get_stack_optional<std::string>(j, "display_login"));
         x.set_gravatar_id(j.at("gravatar_id").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_login(j.at("login").get<std::string>());
         x.set_url(j.at("url").get<std::string>());
@@ -1194,6 +1195,7 @@ namespace quicktype {
         x.set_gists_url(j.at("gists_url").get<std::string>());
         x.set_gravatar_id(j.at("gravatar_id").get<std::string>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_login(j.at("login").get<std::string>());
         x.set_organizations_url(j.at("organizations_url").get<std::string>());
@@ -1247,7 +1249,9 @@ namespace quicktype {
         x.set_downloads_url(j.at("downloads_url").get<std::string>());
         x.set_events_url(j.at("events_url").get<std::string>());
         x.set_fork(j.at("fork").get<bool>());
+        if (j.find("forks") != j.end() && !j.at("forks").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_forks(j.at("forks").get<int64_t>());
+        if (j.find("forks_count") != j.end() && !j.at("forks_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_forks_count(j.at("forks_count").get<int64_t>());
         x.set_forks_url(j.at("forks_url").get<std::string>());
         x.set_full_name(j.at("full_name").get<std::string>());
@@ -1263,6 +1267,7 @@ namespace quicktype {
         x.set_homepage(get_untyped(j, "homepage"));
         x.set_hooks_url(j.at("hooks_url").get<std::string>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_issue_comment_url(j.at("issue_comment_url").get<std::string>());
         x.set_issue_events_url(j.at("issue_events_url").get<std::string>());
@@ -1276,15 +1281,19 @@ namespace quicktype {
         x.set_mirror_url(get_untyped(j, "mirror_url"));
         x.set_name(j.at("name").get<std::string>());
         x.set_notifications_url(j.at("notifications_url").get<std::string>());
+        if (j.find("open_issues") != j.end() && !j.at("open_issues").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_open_issues(j.at("open_issues").get<int64_t>());
+        if (j.find("open_issues_count") != j.end() && !j.at("open_issues_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_open_issues_count(j.at("open_issues_count").get<int64_t>());
         x.set_owner(j.at("owner").get<MergedBy>());
         x.set_pulls_url(j.at("pulls_url").get<std::string>());
         x.set_pushed_at(j.at("pushed_at").get<std::string>());
         x.set_releases_url(j.at("releases_url").get<std::string>());
         x.set_repo_private(j.at("private").get<bool>());
+        if (j.find("size") != j.end() && !j.at("size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_size(j.at("size").get<int64_t>());
         x.set_ssh_url(j.at("ssh_url").get<std::string>());
+        if (j.find("stargazers_count") != j.end() && !j.at("stargazers_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stargazers_count(j.at("stargazers_count").get<int64_t>());
         x.set_stargazers_url(j.at("stargazers_url").get<std::string>());
         x.set_statuses_url(j.at("statuses_url").get<std::string>());
@@ -1296,7 +1305,9 @@ namespace quicktype {
         x.set_trees_url(j.at("trees_url").get<std::string>());
         x.set_updated_at(j.at("updated_at").get<std::string>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("watchers") != j.end() && !j.at("watchers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_watchers(j.at("watchers").get<int64_t>());
+        if (j.find("watchers_count") != j.end() && !j.at("watchers_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_watchers_count(j.at("watchers_count").get<int64_t>());
     }
 
@@ -1427,22 +1438,28 @@ namespace quicktype {
 
     inline void from_json(const json & j, PullRequest& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("additions") != j.end() && !j.at("additions").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_additions(j.at("additions").get<int64_t>());
         x.set_assignee(get_untyped(j, "assignee"));
         x.set_assignees(j.at("assignees").get<std::vector<nlohmann::json>>());
         x.set_base(j.at("base").get<Base>());
         x.set_body(j.at("body").get<std::string>());
+        if (j.find("changed_files") != j.end() && !j.at("changed_files").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_changed_files(j.at("changed_files").get<int64_t>());
         x.set_closed_at(j.at("closed_at").get<std::string>());
+        if (j.find("comments") != j.end() && !j.at("comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_comments(j.at("comments").get<int64_t>());
         x.set_comments_url(j.at("comments_url").get<std::string>());
+        if (j.find("commits") != j.end() && !j.at("commits").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_commits(j.at("commits").get<int64_t>());
         x.set_commits_url(j.at("commits_url").get<std::string>());
         x.set_created_at(j.at("created_at").get<std::string>());
+        if (j.find("deletions") != j.end() && !j.at("deletions").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_deletions(j.at("deletions").get<int64_t>());
         x.set_diff_url(j.at("diff_url").get<std::string>());
         x.set_head(j.at("head").get<Base>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_issue_url(j.at("issue_url").get<std::string>());
         x.set_links(j.at("_links").get<Links>());
@@ -1455,11 +1472,13 @@ namespace quicktype {
         x.set_merged_at(j.at("merged_at").get<std::string>());
         x.set_merged_by(j.at("merged_by").get<MergedBy>());
         x.set_milestone(get_untyped(j, "milestone"));
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(j.at("number").get<int64_t>());
         x.set_patch_url(j.at("patch_url").get<std::string>());
         x.set_rebaseable(get_untyped(j, "rebaseable"));
         x.set_requested_reviewers(j.at("requested_reviewers").get<std::vector<nlohmann::json>>());
         x.set_review_comment_url(j.at("review_comment_url").get<std::string>());
+        if (j.find("review_comments") != j.end() && !j.at("review_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_review_comments(j.at("review_comments").get<int64_t>());
         x.set_review_comments_url(j.at("review_comments_url").get<std::string>());
         x.set_state(j.at("state").get<std::string>());
@@ -1521,15 +1540,19 @@ namespace quicktype {
         x.set_before(get_stack_optional<std::string>(j, "before"));
         x.set_commits(get_stack_optional<std::vector<Commit>>(j, "commits"));
         x.set_description(get_stack_optional<std::string>(j, "description"));
+        if (j.find("distinct_size") != j.end() && !j.at("distinct_size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_distinct_size(get_stack_optional<int64_t>(j, "distinct_size"));
         x.set_head(get_stack_optional<std::string>(j, "head"));
         x.set_master_branch(get_stack_optional<std::string>(j, "master_branch"));
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(get_stack_optional<int64_t>(j, "number"));
         x.set_pull_request(get_stack_optional<PullRequest>(j, "pull_request"));
+        if (j.find("push_id") != j.end() && !j.at("push_id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_push_id(get_stack_optional<int64_t>(j, "push_id"));
         x.set_pusher_type(get_stack_optional<std::string>(j, "pusher_type"));
         x.set_ref(get_stack_optional<std::string>(j, "ref"));
         x.set_ref_type(get_stack_optional<std::string>(j, "ref_type"));
+        if (j.find("size") != j.end() && !j.at("size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_size(get_stack_optional<int64_t>(j, "size"));
     }
 
@@ -1553,6 +1576,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelRepo& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_url(j.at("url").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/0b91a.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/0b91a.json/default/quicktype.hpp
index c9b365b..43128ec 100644
--- a/base/cplusplus/test/inputs/json/misc/0b91a.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/0b91a.json/default/quicktype.hpp
@@ -238,6 +238,7 @@ namespace quicktype {
     inline void from_json(const json & j, ResponseInfo& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_developer_message(j.at("developerMessage").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -249,8 +250,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Resultset& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pagesize") != j.end() && !j.at("pagesize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pagesize(j.at("pagesize").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/0cffa.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/0cffa.json/default/quicktype.hpp
index 6c3da64..523a042 100644
--- a/base/cplusplus/test/inputs/json/misc/0cffa.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/0cffa.json/default/quicktype.hpp
@@ -760,6 +760,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -799,6 +800,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -811,8 +813,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/0e0c2.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/0e0c2.json/default/quicktype.hpp
index 1d8a59c..e50cda0 100644
--- a/base/cplusplus/test/inputs/json/misc/0e0c2.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/0e0c2.json/default/quicktype.hpp
@@ -426,6 +426,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Collection& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_movies(j.at("movies").get<std::vector<int64_t>>());
         x.set_name(j.at("name").get<std::string>());
@@ -444,6 +445,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_cast(j.at("cast").get<std::string>());
         x.set_director(j.at("director").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_language(j.at("language").get<DetailLanguage>());
         x.set_storyline(j.at("storyline").get<std::string>());
@@ -478,7 +480,9 @@ namespace quicktype {
 
     inline void from_json(const json & j, Image& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("favs") != j.end() && !j.at("favs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_favs(j.at("favs").get<int64_t>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_thumbnail(j.at("thumbnail").get<std::string>());
         x.set_type(j.at("type").get<Type>());
@@ -512,8 +516,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, VoteScore& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("avg") != j.end() && !j.at("avg").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_avg(j.at("avg").get<int64_t>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
@@ -526,20 +533,25 @@ namespace quicktype {
 
     inline void from_json(const json & j, Result& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("active_screens") != j.end() && !j.at("active_screens").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_active_screens(j.at("active_screens").get<int64_t>());
         x.set_collections(j.at("collections").get<std::vector<Collection>>());
         x.set_details(j.at("details").get<std::vector<Detail>>());
+        if (j.find("duration") != j.end() && !j.at("duration").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_duration(j.at("duration").get<int64_t>());
         x.set_fav_movie(j.at("fav_movie").get<FavMovie>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_images(j.at("images").get<std::vector<Image>>());
         x.set_language(j.at("language").get<ResultLanguage>());
         x.set_release_date(j.at("release_date").get<std::string>());
+        if (j.find("stars") != j.end() && !j.at("stars").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stars(j.at("stars").get<int64_t>());
         x.set_tags(get_stack_optional<std::vector<nlohmann::json>>(j, "tags"));
         x.set_title(j.at("title").get<std::string>());
         x.set_videos(j.at("videos").get<std::vector<Video>>());
         x.set_vote_score(j.at("vote_score").get<VoteScore>());
+        if (j.find("watches") != j.end() && !j.at("watches").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_watches(j.at("watches").get<int64_t>());
     }
 
@@ -564,6 +576,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
         x.set_previous(get_untyped(j, "previous"));
diff --git a/base/cplusplus/test/inputs/json/misc/127a1.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/127a1.json/default/quicktype.hpp
index cbbd5b4..f6bd52a 100644
--- a/base/cplusplus/test/inputs/json/misc/127a1.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/127a1.json/default/quicktype.hpp
@@ -760,6 +760,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -799,6 +800,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -811,8 +813,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/13d8d.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/13d8d.json/default/quicktype.hpp
index e0402ee..eaafd43 100644
--- a/base/cplusplus/test/inputs/json/misc/13d8d.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/13d8d.json/default/quicktype.hpp
@@ -165,6 +165,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Street& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
     }
@@ -205,6 +206,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_category(j.at("category").get<std::string>());
         x.set_context(j.at("context").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_location(j.at("location").get<Location>());
         x.set_location_subtype(j.at("location_subtype").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/16bc5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/16bc5.json/default/quicktype.hpp
index 4e05a8b..b1147bf 100644
--- a/base/cplusplus/test/inputs/json/misc/16bc5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/16bc5.json/default/quicktype.hpp
@@ -709,6 +709,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/176f1.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/176f1.json/default/quicktype.hpp
index 0c7fe9a..c213179 100644
--- a/base/cplusplus/test/inputs/json/misc/176f1.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/176f1.json/default/quicktype.hpp
@@ -275,6 +275,7 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_message(j.at("message").get<std::vector<nlohmann::json>>());
+        if (j.find("responseTime") != j.end() && !j.at("responseTime").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_response_time(j.at("responseTime").get<int64_t>());
         x.set_results(j.at("Results").get<Results>());
         x.set_status(j.at("status").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/1a7f5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/1a7f5.json/default/quicktype.hpp
index d1fb096..0186ce1 100644
--- a/base/cplusplus/test/inputs/json/misc/1a7f5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/1a7f5.json/default/quicktype.hpp
@@ -84,11 +84,16 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_country(j.at("country").get<Country>());
+        if (j.find("females") != j.end() && !j.at("females").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_females(j.at("females").get<int64_t>());
+        if (j.find("males") != j.end() && !j.at("males").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_males(j.at("males").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/1b28c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/1b28c.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/1b28c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/1b28c.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/1b409.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/1b409.json/default/quicktype.hpp
index 1cf7365..a65d83a 100644
--- a/base/cplusplus/test/inputs/json/misc/1b409.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/1b409.json/default/quicktype.hpp
@@ -427,8 +427,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Meta& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
@@ -461,10 +464,12 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_bioguideid(j.at("bioguideid").get<std::string>());
         x.set_birthday(j.at("birthday").get<std::string>());
+        if (j.find("cspanid") != j.end() && !j.at("cspanid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cspanid(j.at("cspanid").get<int64_t>());
         x.set_firstname(j.at("firstname").get<std::string>());
         x.set_gender(j.at("gender").get<Gender>());
         x.set_gender_label(j.at("gender_label").get<GenderLabel>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_lastname(j.at("lastname").get<std::string>());
         x.set_link(j.at("link").get<std::string>());
@@ -507,9 +512,11 @@ namespace quicktype {
         x.set_congress_numbers(j.at("congress_numbers").get<std::vector<int64_t>>());
         x.set_current(j.at("current").get<bool>());
         x.set_description(j.at("description").get<std::string>());
+        if (j.find("district") != j.end() && !j.at("district").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_district(j.at("district").get<int64_t>());
         x.set_enddate(j.at("enddate").get<std::string>());
         x.set_extra(j.at("extra").get<Extra>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_leadership_title(get_stack_optional<std::string>(j, "leadership_title"));
         x.set_party(j.at("party").get<Party>());
diff --git a/base/cplusplus/test/inputs/json/misc/262f0.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/262f0.json/default/quicktype.hpp
index 92163b0..28095f4 100644
--- a/base/cplusplus/test/inputs/json/misc/262f0.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/262f0.json/default/quicktype.hpp
@@ -714,6 +714,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/26b49.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/26b49.json/default/quicktype.hpp
index 9fb7c13..c344143 100644
--- a/base/cplusplus/test/inputs/json/misc/26b49.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/26b49.json/default/quicktype.hpp
@@ -762,6 +762,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -801,6 +802,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -813,8 +815,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/26c9c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/26c9c.json/default/quicktype.hpp
index f58570b..6b3880e 100644
--- a/base/cplusplus/test/inputs/json/misc/26c9c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/26c9c.json/default/quicktype.hpp
@@ -976,6 +976,7 @@ struct adl_serializer<std::variant<int64_t, std::string>> {
 namespace quicktype {
     inline void from_json(const json & j, Top& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_item(j.at("item").get<std::string>());
     }
@@ -990,7 +991,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_average(get_stack_optional<std::string>(j, "average"));
         x.set_largest(j.at("largest").get<std::string>());
+        if (j.find("non_null") != j.end() && !j.at("non_null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_non_null(j.at("non_null").get<int64_t>());
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
         x.set_smallest(j.at("smallest").get<std::string>());
         x.set_sum(get_stack_optional<std::string>(j, "sum"));
@@ -1031,11 +1034,15 @@ namespace quicktype {
         x.set_field_name(j.at("fieldName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_format(j.at("format").get<Format>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
         x.set_render_type_name(j.at("renderTypeName").get<std::string>());
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(get_stack_optional<int64_t>(j, "tableColumnId"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -1262,6 +1269,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Expression& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("columnId") != j.end() && !j.at("columnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_column_id(j.at("columnId").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
     }
@@ -1298,40 +1306,53 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_attribution(j.at("attribution").get<std::string>());
         x.set_attribution_link(j.at("attributionLink").get<std::string>());
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(j.at("category").get<std::string>());
         x.set_columns(j.at("columns").get<std::vector<Column>>());
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_description(j.at("description").get<std::string>());
         x.set_display_type(j.at("displayType").get<std::string>());
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(j.at("flags").get<std::vector<std::string>>());
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(j.at("indexUpdatedAt").get<int64_t>());
         x.set_locale(j.at("locale").get<std::string>());
         x.set_metadata(j.at("metadata").get<Metadata>());
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<std::string>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(j.at("publicationDate").get<int64_t>());
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<std::string>());
         x.set_query(j.at("query").get<Query>());
         x.set_rights(j.at("rights").get<std::vector<std::string>>());
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(j.at("rowsUpdatedAt").get<int64_t>());
         x.set_rows_updated_by(j.at("rowsUpdatedBy").get<std::string>());
         x.set_table_author(j.at("tableAuthor").get<Owner>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
         x.set_tags(j.at("tags").get<std::vector<std::string>>());
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/27332.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/27332.json/default/quicktype.hpp
index c5f3a1b..06d1b8c 100644
--- a/base/cplusplus/test/inputs/json/misc/27332.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/27332.json/default/quicktype.hpp
@@ -746,16 +746,20 @@ namespace quicktype {
     inline void from_json(const json & j, Oembed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_description(j.at("description").get<std::string>());
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_html(j.at("html").get<std::string>());
         x.set_provider_name(j.at("provider_name").get<std::string>());
         x.set_provider_url(j.at("provider_url").get<std::string>());
+        if (j.find("thumbnail_height") != j.end() && !j.at("thumbnail_height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_height(j.at("thumbnail_height").get<int64_t>());
         x.set_thumbnail_url(j.at("thumbnail_url").get<std::string>());
+        if (j.find("thumbnail_width") != j.end() && !j.at("thumbnail_width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_width(j.at("thumbnail_width").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_type(j.at("type").get<std::string>());
         x.set_version(j.at("version").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -790,8 +794,10 @@ namespace quicktype {
     inline void from_json(const json & j, MediaEmbed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_content(get_stack_optional<std::string>(j, "content"));
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(get_stack_optional<int64_t>(j, "height"));
         x.set_scrolling(get_stack_optional<bool>(j, "scrolling"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -805,8 +811,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -875,8 +883,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(get_stack_optional<std::string>(j, "distinguished"));
         x.set_domain(j.at("domain").get<Domain>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -891,6 +901,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -901,6 +912,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_stack_optional<Media>(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -917,6 +929,7 @@ namespace quicktype {
         x.set_thumbnail_height(get_stack_optional<int64_t>(j, "thumbnail_height"));
         x.set_thumbnail_width(get_stack_optional<int64_t>(j, "thumbnail_width"));
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/29f47.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/29f47.json/default/quicktype.hpp
index 264563e..a3b8427 100644
--- a/base/cplusplus/test/inputs/json/misc/29f47.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/29f47.json/default/quicktype.hpp
@@ -696,8 +696,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -779,8 +781,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(j.at("distinguished").get<Distinguished>());
         x.set_domain(j.at("domain").get<Domain>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<Edited>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -795,6 +799,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -805,6 +810,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_untyped(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -821,6 +827,7 @@ namespace quicktype {
         x.set_thumbnail_height(get_stack_optional<int64_t>(j, "thumbnail_height"));
         x.set_thumbnail_width(get_stack_optional<int64_t>(j, "thumbnail_width"));
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/2d4e2.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/2d4e2.json/default/quicktype.hpp
index 11e5a96..6ec059b 100644
--- a/base/cplusplus/test/inputs/json/misc/2d4e2.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/2d4e2.json/default/quicktype.hpp
@@ -458,8 +458,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Meta& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
@@ -492,10 +495,12 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_bioguideid(j.at("bioguideid").get<std::string>());
         x.set_birthday(j.at("birthday").get<std::string>());
+        if (j.find("cspanid") != j.end() && !j.at("cspanid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cspanid(j.at("cspanid").get<int64_t>());
         x.set_firstname(j.at("firstname").get<std::string>());
         x.set_gender(j.at("gender").get<Gender>());
         x.set_gender_label(j.at("gender_label").get<GenderLabel>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_lastname(j.at("lastname").get<std::string>());
         x.set_link(j.at("link").get<std::string>());
@@ -541,6 +546,7 @@ namespace quicktype {
         x.set_district(get_untyped(j, "district"));
         x.set_enddate(j.at("enddate").get<std::string>());
         x.set_extra(j.at("extra").get<Extra>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_leadership_title(get_stack_optional<std::string>(j, "leadership_title"));
         x.set_party(j.at("party").get<Party>());
diff --git a/base/cplusplus/test/inputs/json/misc/2df80.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/2df80.json/default/quicktype.hpp
index 6734feb..9873ff4 100644
--- a/base/cplusplus/test/inputs/json/misc/2df80.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/2df80.json/default/quicktype.hpp
@@ -271,9 +271,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, FluffyTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pages") != j.end() && !j.at("pages").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pages(j.at("pages").get<int64_t>());
         x.set_per_page(j.at("per_page").get<std::string>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/32431.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/32431.json/default/quicktype.hpp
index c966edb..11680f5 100644
--- a/base/cplusplus/test/inputs/json/misc/32431.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/32431.json/default/quicktype.hpp
@@ -410,15 +410,20 @@ namespace quicktype {
         x.set_nst(get_stack_optional<int64_t>(j, "nst"));
         x.set_place(j.at("place").get<std::string>());
         x.set_rms(j.at("rms").get<double>());
+        if (j.find("sig") != j.end() && !j.at("sig").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sig(j.at("sig").get<int64_t>());
         x.set_sources(j.at("sources").get<std::string>());
         x.set_status(j.at("status").get<Status>());
+        if (j.find("time") != j.end() && !j.at("time").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_time(j.at("time").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("tsunami") != j.end() && !j.at("tsunami").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tsunami(j.at("tsunami").get<int64_t>());
         x.set_type(j.at("type").get<PropertiesType>());
         x.set_types(j.at("types").get<std::string>());
+        if (j.find("tz") != j.end() && !j.at("tz").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tz(j.at("tz").get<int64_t>());
+        if (j.find("updated") != j.end() && !j.at("updated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_updated(j.at("updated").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
     }
@@ -472,8 +477,11 @@ namespace quicktype {
     inline void from_json(const json & j, Metadata& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_api(j.at("api").get<std::string>());
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("generated") != j.end() && !j.at("generated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_generated(j.at("generated").get<int64_t>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_url(j.at("url").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/32d5c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/32d5c.json/default/quicktype.hpp
index ec5782c..0640812 100644
--- a/base/cplusplus/test/inputs/json/misc/32d5c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/32d5c.json/default/quicktype.hpp
@@ -146,9 +146,11 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_birth_date(get_stack_optional<std::string>(j, "BirthDate"));
         x.set_birth_date_is_protected(j.at("BirthDateIsProtected").get<bool>());
+        if (j.find("GenderTypeID") != j.end() && !j.at("GenderTypeID").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gender_type_id(j.at("GenderTypeID").get<int64_t>());
         x.set_notes(j.at("Notes").get<std::string>());
         x.set_parliamentary_name(j.at("ParliamentaryName").get<std::string>());
+        if (j.find("PersonID") != j.end() && !j.at("PersonID").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_person_id(j.at("PersonID").get<int64_t>());
         x.set_photo_url(j.at("PhotoURL").get<std::string>());
         x.set_preferred_name(j.at("PreferredName").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/337ed.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/337ed.json/default/quicktype.hpp
index 7c718b6..a09b323 100644
--- a/base/cplusplus/test/inputs/json/misc/337ed.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/337ed.json/default/quicktype.hpp
@@ -384,6 +384,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, CustomIncome& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("amount") != j.end() && !j.at("amount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_amount(j.at("amount").get<int64_t>());
         x.set_created_at(j.at("created_at").get<std::string>());
         x.set_id(j.at("id").get<std::string>());
@@ -416,8 +417,10 @@ namespace quicktype {
         x.set_direct_rep_costs_max(get_untyped(j, "direct_rep_costs_max"));
         x.set_direct_rep_costs_min(get_untyped(j, "direct_rep_costs_min"));
         x.set_end_date(j.at("end_date").get<std::string>());
+        if (j.find("eur_sources_grants") != j.end() && !j.at("eur_sources_grants").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eur_sources_grants(j.at("eur_sources_grants").get<int64_t>());
         x.set_eur_sources_grants_src(get_stack_optional<std::string>(j, "eur_sources_grants_src"));
+        if (j.find("eur_sources_procurement") != j.end() && !j.at("eur_sources_procurement").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eur_sources_procurement(j.at("eur_sources_procurement").get<int64_t>());
         x.set_eur_sources_procurement_src(get_stack_optional<std::string>(j, "eur_sources_procurement_src"));
         x.set_id(j.at("id").get<std::string>());
@@ -480,10 +483,13 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_facets(j.at("facets").get<Facets>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(j.at("previous").get<bool>());
         x.set_results(j.at("results").get<std::vector<Result>>());
diff --git a/base/cplusplus/test/inputs/json/misc/34702.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/34702.json/default/quicktype.hpp
index 9012407..85426f2 100644
--- a/base/cplusplus/test/inputs/json/misc/34702.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/34702.json/default/quicktype.hpp
@@ -378,6 +378,7 @@ namespace quicktype {
         x.set_longitude(j.at("longitude").get<double>());
         x.set_no(get_stack_optional<std::string>(j, "no"));
         x.set_phone(j.at("phone").get<double>());
+        if (j.find("postcode") != j.end() && !j.at("postcode").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_postcode(j.at("postcode").get<int64_t>());
         x.set_psa(j.at("psa").get<std::string>());
         x.set_region(j.at("region").get<Region>());
@@ -428,6 +429,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_crs(j.at("crs").get<Crs>());
         x.set_features(j.at("features").get<std::vector<Feature>>());
+        if (j.find("totalFeatures") != j.end() && !j.at("totalFeatures").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_features(j.at("totalFeatures").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/3659d.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/3659d.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/3659d.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/3659d.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/3e9a3.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/3e9a3.json/default/quicktype.hpp
index 0c7fe9a..c213179 100644
--- a/base/cplusplus/test/inputs/json/misc/3e9a3.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/3e9a3.json/default/quicktype.hpp
@@ -275,6 +275,7 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_message(j.at("message").get<std::vector<nlohmann::json>>());
+        if (j.find("responseTime") != j.end() && !j.at("responseTime").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_response_time(j.at("responseTime").get<int64_t>());
         x.set_results(j.at("Results").get<Results>());
         x.set_status(j.at("status").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/3f1ce.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/3f1ce.json/default/quicktype.hpp
index aca34d9..dd5e572 100644
--- a/base/cplusplus/test/inputs/json/misc/3f1ce.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/3f1ce.json/default/quicktype.hpp
@@ -714,6 +714,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/421d4.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/421d4.json/default/quicktype.hpp
index 5de2f7a..465cebe 100644
--- a/base/cplusplus/test/inputs/json/misc/421d4.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/421d4.json/default/quicktype.hpp
@@ -645,6 +645,7 @@ struct adl_serializer<std::variant<int64_t, std::string>> {
 namespace quicktype {
     inline void from_json(const json & j, Top& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_item(j.at("item").get<std::string>());
     }
@@ -659,7 +660,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_average(get_stack_optional<std::string>(j, "average"));
         x.set_largest(get_stack_optional<std::string>(j, "largest"));
+        if (j.find("non_null") != j.end() && !j.at("non_null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_non_null(j.at("non_null").get<int64_t>());
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
         x.set_smallest(get_stack_optional<std::string>(j, "smallest"));
         x.set_sum(get_stack_optional<std::string>(j, "sum"));
@@ -695,11 +698,15 @@ namespace quicktype {
         x.set_field_name(j.at("fieldName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_format(j.at("format").get<Query>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
         x.set_render_type_name(j.at("renderTypeName").get<std::string>());
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(get_stack_optional<int64_t>(j, "tableColumnId"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -797,18 +804,22 @@ namespace quicktype {
     inline void from_json(const json & j, View& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_attribution(j.at("attribution").get<std::string>());
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(j.at("category").get<std::string>());
         x.set_columns(j.at("columns").get<std::vector<Column>>());
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_description(j.at("description").get<std::string>());
         x.set_display_type(j.at("displayType").get<std::string>());
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(j.at("flags").get<std::vector<std::string>>());
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(j.at("indexUpdatedAt").get<int64_t>());
         x.set_license(j.at("license").get<License>());
         x.set_license_id(j.at("licenseId").get<std::string>());
@@ -816,24 +827,33 @@ namespace quicktype {
         x.set_metadata(j.at("metadata").get<Metadata>());
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<std::string>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(j.at("publicationDate").get<int64_t>());
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<std::string>());
         x.set_query(j.at("query").get<Query>());
         x.set_rights(j.at("rights").get<std::vector<std::string>>());
         x.set_row_class(j.at("rowClass").get<std::string>());
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(j.at("rowsUpdatedAt").get<int64_t>());
         x.set_rows_updated_by(j.at("rowsUpdatedBy").get<std::string>());
         x.set_table_author(j.at("tableAuthor").get<Owner>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
         x.set_tags(j.at("tags").get<std::vector<std::string>>());
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/437e7.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/437e7.json/default/quicktype.hpp
index 716b804..d851b06 100644
--- a/base/cplusplus/test/inputs/json/misc/437e7.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/437e7.json/default/quicktype.hpp
@@ -741,6 +741,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -780,6 +781,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -792,8 +794,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/43970.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/43970.json/default/quicktype.hpp
index b144c70..216910b 100644
--- a/base/cplusplus/test/inputs/json/misc/43970.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/43970.json/default/quicktype.hpp
@@ -64,6 +64,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("ID") != j.end() && !j.at("ID").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("ID").get<int64_t>());
         x.set_name(j.at("Name").get<std::string>());
         x.set_notes(j.at("Notes").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/458db.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/458db.json/default/quicktype.hpp
index 09b9d0d..c591296 100644
--- a/base/cplusplus/test/inputs/json/misc/458db.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/458db.json/default/quicktype.hpp
@@ -238,6 +238,7 @@ namespace quicktype {
     inline void from_json(const json & j, ResponseInfo& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_developer_message(j.at("developerMessage").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -249,8 +250,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Resultset& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pagesize") != j.end() && !j.at("pagesize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pagesize(j.at("pagesize").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/4961a.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/4961a.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/4961a.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/4961a.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/4a0d7.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/4a0d7.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/4a0d7.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/4a0d7.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/4a455.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/4a455.json/default/quicktype.hpp
index c713742..3b20de5 100644
--- a/base/cplusplus/test/inputs/json/misc/4a455.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/4a455.json/default/quicktype.hpp
@@ -296,6 +296,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_crs(j.at("crs").get<Crs>());
         x.set_features(j.at("features").get<std::vector<Feature>>());
+        if (j.find("totalFeatures") != j.end() && !j.at("totalFeatures").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_features(j.at("totalFeatures").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/4c547.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/4c547.json/default/quicktype.hpp
index 4e05a8b..b1147bf 100644
--- a/base/cplusplus/test/inputs/json/misc/4c547.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/4c547.json/default/quicktype.hpp
@@ -709,6 +709,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/4d6fb.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/4d6fb.json/default/quicktype.hpp
index 4c2e027..55ed181 100644
--- a/base/cplusplus/test/inputs/json/misc/4d6fb.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/4d6fb.json/default/quicktype.hpp
@@ -753,16 +753,20 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_author_name(j.at("author_name").get<std::string>());
         x.set_author_url(j.at("author_url").get<std::string>());
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_html(j.at("html").get<std::string>());
         x.set_provider_name(j.at("provider_name").get<std::string>());
         x.set_provider_url(j.at("provider_url").get<std::string>());
+        if (j.find("thumbnail_height") != j.end() && !j.at("thumbnail_height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_height(j.at("thumbnail_height").get<int64_t>());
         x.set_thumbnail_url(j.at("thumbnail_url").get<std::string>());
+        if (j.find("thumbnail_width") != j.end() && !j.at("thumbnail_width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_width(j.at("thumbnail_width").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_type(j.at("type").get<std::string>());
         x.set_version(j.at("version").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -798,8 +802,10 @@ namespace quicktype {
     inline void from_json(const json & j, MediaEmbed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_content(get_stack_optional<std::string>(j, "content"));
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(get_stack_optional<int64_t>(j, "height"));
         x.set_scrolling(get_stack_optional<bool>(j, "scrolling"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -813,8 +819,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -883,8 +891,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(get_untyped(j, "distinguished"));
         x.set_domain(j.at("domain").get<std::string>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -899,6 +909,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -909,6 +920,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_stack_optional<Media>(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -925,6 +937,7 @@ namespace quicktype {
         x.set_thumbnail_height(get_stack_optional<int64_t>(j, "thumbnail_height"));
         x.set_thumbnail_width(get_stack_optional<int64_t>(j, "thumbnail_width"));
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/4e336.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/4e336.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/4e336.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/4e336.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/54d32.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/54d32.json/default/quicktype.hpp
index 3ddcdaf..a144f0d 100644
--- a/base/cplusplus/test/inputs/json/misc/54d32.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/54d32.json/default/quicktype.hpp
@@ -173,10 +173,13 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_facets(j.at("facets").get<Facets>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(j.at("previous").get<bool>());
         x.set_results(j.at("results").get<std::vector<Result>>());
diff --git a/base/cplusplus/test/inputs/json/misc/5eae5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/5eae5.json/default/quicktype.hpp
index 9c53878..fc4edad 100644
--- a/base/cplusplus/test/inputs/json/misc/5eae5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/5eae5.json/default/quicktype.hpp
@@ -70,6 +70,7 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("Date").get<std::string>());
+        if (j.find("ID") != j.end() && !j.at("ID").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("ID").get<int64_t>());
         x.set_sponsor(j.at("Sponsor").get<std::string>());
         x.set_title(j.at("Title").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/5f7fe.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/5f7fe.json/default/quicktype.hpp
index 9e89313..d10de4b 100644
--- a/base/cplusplus/test/inputs/json/misc/5f7fe.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/5f7fe.json/default/quicktype.hpp
@@ -961,6 +961,7 @@ struct adl_serializer<std::variant<int64_t, std::string>> {
 namespace quicktype {
     inline void from_json(const json & j, Top& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_item(j.at("item").get<std::string>());
     }
@@ -974,7 +975,9 @@ namespace quicktype {
     inline void from_json(const json & j, CachedContents& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_largest(j.at("largest").get<std::string>());
+        if (j.find("non_null") != j.end() && !j.at("non_null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_non_null(j.at("non_null").get<int64_t>());
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
         x.set_smallest(j.at("smallest").get<std::string>());
         x.set_top(j.at("top").get<std::vector<Top>>());
@@ -1008,11 +1011,15 @@ namespace quicktype {
         x.set_field_name(j.at("fieldName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_format(j.at("format").get<Format>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
         x.set_render_type_name(j.at("renderTypeName").get<TypeName>());
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(get_stack_optional<int64_t>(j, "tableColumnId"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -1239,6 +1246,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Expression& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("columnId") != j.end() && !j.at("columnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_column_id(j.at("columnId").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
     }
@@ -1275,40 +1283,53 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_attribution(j.at("attribution").get<std::string>());
         x.set_attribution_link(j.at("attributionLink").get<std::string>());
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(j.at("category").get<std::string>());
         x.set_columns(j.at("columns").get<std::vector<Column>>());
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_description(j.at("description").get<std::string>());
         x.set_display_type(j.at("displayType").get<std::string>());
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(j.at("flags").get<std::vector<std::string>>());
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(j.at("indexUpdatedAt").get<int64_t>());
         x.set_locale(j.at("locale").get<std::string>());
         x.set_metadata(j.at("metadata").get<Metadata>());
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<std::string>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(j.at("publicationDate").get<int64_t>());
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<std::string>());
         x.set_query(j.at("query").get<Query>());
         x.set_rights(j.at("rights").get<std::vector<std::string>>());
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(j.at("rowsUpdatedAt").get<int64_t>());
         x.set_rows_updated_by(j.at("rowsUpdatedBy").get<std::string>());
         x.set_table_author(j.at("tableAuthor").get<Owner>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
         x.set_tags(j.at("tags").get<std::vector<std::string>>());
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/617e8.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/617e8.json/default/quicktype.hpp
index 7105104..de4a08a 100644
--- a/base/cplusplus/test/inputs/json/misc/617e8.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/617e8.json/default/quicktype.hpp
@@ -956,6 +956,7 @@ struct adl_serializer<std::variant<int64_t, std::string>> {
 namespace quicktype {
     inline void from_json(const json & j, Top& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_item(j.at("item").get<std::string>());
     }
@@ -969,7 +970,9 @@ namespace quicktype {
     inline void from_json(const json & j, CachedContents& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_largest(j.at("largest").get<std::string>());
+        if (j.find("non_null") != j.end() && !j.at("non_null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_non_null(j.at("non_null").get<int64_t>());
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
         x.set_smallest(j.at("smallest").get<std::string>());
         x.set_top(j.at("top").get<std::vector<Top>>());
@@ -1004,11 +1007,15 @@ namespace quicktype {
         x.set_field_name(j.at("fieldName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_format(j.at("format").get<Format>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
         x.set_render_type_name(j.at("renderTypeName").get<TypeName>());
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(get_stack_optional<int64_t>(j, "tableColumnId"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -1232,6 +1239,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Expression& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("columnId") != j.end() && !j.at("columnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_column_id(j.at("columnId").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
     }
@@ -1268,40 +1276,53 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_attribution(j.at("attribution").get<std::string>());
         x.set_attribution_link(j.at("attributionLink").get<std::string>());
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(j.at("category").get<std::string>());
         x.set_columns(j.at("columns").get<std::vector<Column>>());
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_description(j.at("description").get<std::string>());
         x.set_display_type(j.at("displayType").get<std::string>());
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(j.at("flags").get<std::vector<std::string>>());
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(j.at("indexUpdatedAt").get<int64_t>());
         x.set_locale(j.at("locale").get<std::string>());
         x.set_metadata(j.at("metadata").get<Metadata>());
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<std::string>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(j.at("publicationDate").get<int64_t>());
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<std::string>());
         x.set_query(j.at("query").get<Query>());
         x.set_rights(j.at("rights").get<std::vector<std::string>>());
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(j.at("rowsUpdatedAt").get<int64_t>());
         x.set_rows_updated_by(j.at("rowsUpdatedBy").get<std::string>());
         x.set_table_author(j.at("tableAuthor").get<Owner>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
         x.set_tags(j.at("tags").get<std::vector<std::string>>());
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/65dec.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/65dec.json/default/quicktype.hpp
index c68d941..bcf6839 100644
--- a/base/cplusplus/test/inputs/json/misc/65dec.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/65dec.json/default/quicktype.hpp
@@ -410,6 +410,7 @@ namespace quicktype {
     inline void from_json(const json & j, Card& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_artist(j.at("artist").get<std::string>());
+        if (j.find("cmc") != j.end() && !j.at("cmc").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cmc(j.at("cmc").get<int64_t>());
         x.set_color_identity(get_stack_optional<std::vector<ColorIdentity>>(j, "colorIdentity"));
         x.set_colors(get_stack_optional<std::vector<Watermark>>(j, "colors"));
@@ -420,6 +421,7 @@ namespace quicktype {
         x.set_legalities(j.at("legalities").get<std::vector<LegalityElement>>());
         x.set_mana_cost(get_stack_optional<std::string>(j, "manaCost"));
         x.set_mci_number(get_stack_optional<std::string>(j, "mciNumber"));
+        if (j.find("multiverseid") != j.end() && !j.at("multiverseid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_multiverseid(j.at("multiverseid").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_original_text(j.at("originalText").get<std::string>());
@@ -479,6 +481,7 @@ namespace quicktype {
         x.set_code(j.at("code").get<std::string>());
         x.set_gatherer_code(j.at("gathererCode").get<std::string>());
         x.set_magic_cards_info_code(j.at("magicCardsInfoCode").get<std::string>());
+        if (j.find("mkm_id") != j.end() && !j.at("mkm_id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mkm_id(j.at("mkm_id").get<int64_t>());
         x.set_mkm_name(j.at("mkm_name").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/6617c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/6617c.json/default/quicktype.hpp
index e0791ca..ab53a67 100644
--- a/base/cplusplus/test/inputs/json/misc/6617c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/6617c.json/default/quicktype.hpp
@@ -98,6 +98,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_iss_position(j.at("iss_position").get<IssPosition>());
         x.set_message(j.at("message").get<std::string>());
+        if (j.find("timestamp") != j.end() && !j.at("timestamp").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_timestamp(j.at("timestamp").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/67c03.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/67c03.json/default/quicktype.hpp
index e939122..d950b3f 100644
--- a/base/cplusplus/test/inputs/json/misc/67c03.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/67c03.json/default/quicktype.hpp
@@ -97,6 +97,7 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_message(j.at("message").get<std::string>());
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(j.at("number").get<int64_t>());
         x.set_people(j.at("people").get<std::vector<Person>>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/68c30.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/68c30.json/default/quicktype.hpp
index 318d40a..6afc395 100644
--- a/base/cplusplus/test/inputs/json/misc/68c30.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/68c30.json/default/quicktype.hpp
@@ -199,11 +199,15 @@ namespace quicktype {
     inline void from_json(const json & j, Out& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_addr(j.at("addr").get<std::string>());
+        if (j.find("n") != j.end() && !j.at("n").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_n(j.at("n").get<int64_t>());
         x.set_script(j.at("script").get<std::string>());
         x.set_spent(j.at("spent").get<bool>());
+        if (j.find("tx_index") != j.end() && !j.at("tx_index").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tx_index(j.at("tx_index").get<int64_t>());
+        if (j.find("type") != j.end() && !j.at("type").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_type(j.at("type").get<int64_t>());
+        if (j.find("value") != j.end() && !j.at("value").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_value(j.at("value").get<int64_t>());
     }
 
@@ -222,6 +226,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_prev_out(j.at("prev_out").get<Out>());
         x.set_script(j.at("script").get<std::string>());
+        if (j.find("sequence") != j.end() && !j.at("sequence").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sequence(j.at("sequence").get<int64_t>());
     }
 
@@ -237,14 +242,21 @@ namespace quicktype {
         x.set_double_spend(j.at("double_spend").get<bool>());
         x.set_hash(j.at("hash").get<std::string>());
         x.set_inputs(j.at("inputs").get<std::vector<Input>>());
+        if (j.find("lock_time") != j.end() && !j.at("lock_time").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lock_time(j.at("lock_time").get<int64_t>());
         x.set_out(j.at("out").get<std::vector<Out>>());
         x.set_relayed_by(j.at("relayed_by").get<std::string>());
+        if (j.find("size") != j.end() && !j.at("size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_size(j.at("size").get<int64_t>());
+        if (j.find("time") != j.end() && !j.at("time").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_time(j.at("time").get<int64_t>());
+        if (j.find("tx_index") != j.end() && !j.at("tx_index").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tx_index(j.at("tx_index").get<int64_t>());
+        if (j.find("ver") != j.end() && !j.at("ver").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ver(j.at("ver").get<int64_t>());
+        if (j.find("vin_sz") != j.end() && !j.at("vin_sz").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_vin_sz(j.at("vin_sz").get<int64_t>());
+        if (j.find("vout_sz") != j.end() && !j.at("vout_sz").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_vout_sz(j.at("vout_sz").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/6c155.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/6c155.json/default/quicktype.hpp
index 0363810..925fbf3 100644
--- a/base/cplusplus/test/inputs/json/misc/6c155.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/6c155.json/default/quicktype.hpp
@@ -300,6 +300,7 @@ namespace quicktype {
     inline void from_json(const json & j, ResponseInfo& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_developer_message(j.at("developerMessage").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -311,8 +312,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Resultset& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pagesize") != j.end() && !j.at("pagesize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pagesize(j.at("pagesize").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/6de06.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/6de06.json/default/quicktype.hpp
index dda609e..57828d7 100644
--- a/base/cplusplus/test/inputs/json/misc/6de06.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/6de06.json/default/quicktype.hpp
@@ -767,16 +767,20 @@ namespace quicktype {
     inline void from_json(const json & j, Oembed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_description(j.at("description").get<std::string>());
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_html(j.at("html").get<std::string>());
         x.set_provider_name(j.at("provider_name").get<std::string>());
         x.set_provider_url(j.at("provider_url").get<std::string>());
+        if (j.find("thumbnail_height") != j.end() && !j.at("thumbnail_height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_height(j.at("thumbnail_height").get<int64_t>());
         x.set_thumbnail_url(j.at("thumbnail_url").get<std::string>());
+        if (j.find("thumbnail_width") != j.end() && !j.at("thumbnail_width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_width(j.at("thumbnail_width").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_type(j.at("type").get<std::string>());
         x.set_version(j.at("version").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -811,8 +815,10 @@ namespace quicktype {
     inline void from_json(const json & j, MediaEmbed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_content(get_stack_optional<std::string>(j, "content"));
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(get_stack_optional<int64_t>(j, "height"));
         x.set_scrolling(get_stack_optional<bool>(j, "scrolling"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -826,8 +832,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -913,8 +921,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(get_untyped(j, "distinguished"));
         x.set_domain(j.at("domain").get<std::string>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -929,6 +939,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -939,6 +950,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_stack_optional<Media>(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -955,6 +967,7 @@ namespace quicktype {
         x.set_thumbnail_height(get_stack_optional<int64_t>(j, "thumbnail_height"));
         x.set_thumbnail_width(get_stack_optional<int64_t>(j, "thumbnail_width"));
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/6dec6.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/6dec6.json/default/quicktype.hpp
index e630c3a..48a3bfc 100644
--- a/base/cplusplus/test/inputs/json/misc/6dec6.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/6dec6.json/default/quicktype.hpp
@@ -714,6 +714,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/6eb00.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/6eb00.json/default/quicktype.hpp
index 7b6b358..cde77d2 100644
--- a/base/cplusplus/test/inputs/json/misc/6eb00.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/6eb00.json/default/quicktype.hpp
@@ -64,7 +64,9 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("DirectorateID") != j.end() && !j.at("DirectorateID").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_directorate_id(j.at("DirectorateID").get<int64_t>());
+        if (j.find("Id") != j.end() && !j.at("Id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("Id").get<int64_t>());
         x.set_name(j.at("Name").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/734ad.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/734ad.json/default/quicktype.hpp
index 457ce38..21b8e0a 100644
--- a/base/cplusplus/test/inputs/json/misc/734ad.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/734ad.json/default/quicktype.hpp
@@ -470,6 +470,7 @@ namespace quicktype {
         x.set_be_office_street(get_stack_optional<std::string>(j, "be_office_street"));
         x.set_be_office_town(get_stack_optional<std::string>(j, "be_office_town"));
         x.set_code_of_conduct(j.at("code_of_conduct").get<std::string>());
+        if (j.find("contact_country") != j.end() && !j.at("contact_country").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_contact_country(j.at("contact_country").get<int64_t>());
         x.set_created_at(j.at("created_at").get<std::string>());
         x.set_entity(j.at("entity").get<std::string>());
@@ -489,8 +490,10 @@ namespace quicktype {
         x.set_last_update_date(j.at("last_update_date").get<std::string>());
         x.set_legal(j.at("legal").get<std::string>());
         x.set_legal_status(j.at("legal_status").get<std::string>());
+        if (j.find("main_category") != j.end() && !j.at("main_category").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_main_category(j.at("main_category").get<int64_t>());
         x.set_main_category_title(j.at("main_category_title").get<std::string>());
+        if (j.find("members") != j.end() && !j.at("members").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_members(j.at("members").get<int64_t>());
         x.set_members_100(get_stack_optional<int64_t>(j, "members_100"));
         x.set_members_25(get_stack_optional<int64_t>(j, "members_25"));
@@ -505,6 +508,7 @@ namespace quicktype {
         x.set_registration_date(j.at("registration_date").get<std::string>());
         x.set_status(j.at("status").get<Status>());
         x.set_structure_members(j.at("structure_members").get<std::string>());
+        if (j.find("sub_category") != j.end() && !j.at("sub_category").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sub_category(j.at("sub_category").get<int64_t>());
         x.set_sub_category_title(j.at("sub_category_title").get<std::string>());
         x.set_updated_at(j.at("updated_at").get<std::string>());
@@ -576,10 +580,13 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_facets(j.at("facets").get<Facets>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(j.at("previous").get<bool>());
         x.set_results(j.at("results").get<std::vector<Result>>());
diff --git a/base/cplusplus/test/inputs/json/misc/7681c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/7681c.json/default/quicktype.hpp
index ff793ac..f77ece1 100644
--- a/base/cplusplus/test/inputs/json/misc/7681c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/7681c.json/default/quicktype.hpp
@@ -760,6 +760,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -799,6 +800,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -811,8 +813,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/7df41.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/7df41.json/default/quicktype.hpp
index 6483d03..6c7424d 100644
--- a/base/cplusplus/test/inputs/json/misc/7df41.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/7df41.json/default/quicktype.hpp
@@ -99,8 +99,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pc& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_label(j.at("label").get<std::string>());
+        if (j.find("peak24") != j.end() && !j.at("peak24").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_peak24(j.at("peak24").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/7dfa6.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/7dfa6.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/7dfa6.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/7dfa6.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/7eb30.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/7eb30.json/default/quicktype.hpp
index 2e559ce..447f425 100644
--- a/base/cplusplus/test/inputs/json/misc/7eb30.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/7eb30.json/default/quicktype.hpp
@@ -227,12 +227,16 @@ namespace quicktype {
         x.set_fav(j.at("fav").get<bool>());
         x.set_group(j.at("group").get<Group>());
         x.set_location(j.at("location").get<Location>());
+        if (j.find("min_screens") != j.end() && !j.at("min_screens").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_min_screens(j.at("min_screens").get<int64_t>());
+        if (j.find("num_views") != j.end() && !j.at("num_views").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_views(j.at("num_views").get<int64_t>());
         x.set_showtimes(j.at("showtimes").get<std::string>());
+        if (j.find("stars") != j.end() && !j.at("stars").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stars(j.at("stars").get<int64_t>());
         x.set_tel(j.at("tel").get<Tel>());
         x.set_thai(j.at("thai").get<std::string>());
+        if (j.find("today_screens") != j.end() && !j.at("today_screens").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_today_screens(j.at("today_screens").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_website(j.at("website").get<std::string>());
@@ -258,6 +262,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
         x.set_previous(get_untyped(j, "previous"));
diff --git a/base/cplusplus/test/inputs/json/misc/7f568.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/7f568.json/default/quicktype.hpp
index 51827f0..d01cab0 100644
--- a/base/cplusplus/test/inputs/json/misc/7f568.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/7f568.json/default/quicktype.hpp
@@ -233,6 +233,7 @@ namespace quicktype {
         x.set_filename(j.at("filename").get<std::string>());
         x.set_language(get_stack_optional<Language>(j, "language"));
         x.set_raw_url(j.at("raw_url").get<std::string>());
+        if (j.find("size") != j.end() && !j.at("size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_size(j.at("size").get<int64_t>());
         x.set_type(j.at("type").get<Type>());
     }
@@ -248,6 +249,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("comments") != j.end() && !j.at("comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_comments(j.at("comments").get<int64_t>());
         x.set_comments_url(j.at("comments_url").get<std::string>());
         x.set_commits_url(j.at("commits_url").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/7fbfb.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/7fbfb.json/default/quicktype.hpp
index 333add0..cc0699f 100644
--- a/base/cplusplus/test/inputs/json/misc/7fbfb.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/7fbfb.json/default/quicktype.hpp
@@ -235,9 +235,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, FluffyTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pages") != j.end() && !j.at("pages").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pages(j.at("pages").get<int64_t>());
         x.set_per_page(j.at("per_page").get<std::string>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/80aff.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/80aff.json/default/quicktype.hpp
index d864d9b..10162b1 100644
--- a/base/cplusplus/test/inputs/json/misc/80aff.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/80aff.json/default/quicktype.hpp
@@ -209,7 +209,9 @@ namespace quicktype {
     inline void from_json(const json & j, Result& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_created_at(j.at("created_at").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("items") != j.end() && !j.at("items").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_items(j.at("items").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_parent(get_stack_optional<int64_t>(j, "parent"));
@@ -230,10 +232,13 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_facets(j.at("facets").get<Facets>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(j.at("next").get<bool>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(j.at("previous").get<bool>());
         x.set_results(j.at("results").get<std::vector<Result>>());
diff --git a/base/cplusplus/test/inputs/json/misc/8592b.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/8592b.json/default/quicktype.hpp
index d2ac94a..6c6b59a 100644
--- a/base/cplusplus/test/inputs/json/misc/8592b.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/8592b.json/default/quicktype.hpp
@@ -635,8 +635,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -694,8 +696,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(get_untyped(j, "distinguished"));
         x.set_domain(j.at("domain").get<std::string>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -710,6 +714,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -720,6 +725,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_untyped(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -736,6 +742,7 @@ namespace quicktype {
         x.set_thumbnail_height(get_stack_optional<int64_t>(j, "thumbnail_height"));
         x.set_thumbnail_width(get_stack_optional<int64_t>(j, "thumbnail_width"));
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/88130.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/88130.json/default/quicktype.hpp
index 4e05a8b..b1147bf 100644
--- a/base/cplusplus/test/inputs/json/misc/88130.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/88130.json/default/quicktype.hpp
@@ -709,6 +709,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/8a62c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/8a62c.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/8a62c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/8a62c.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/9929c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/9929c.json/default/quicktype.hpp
index 4e05a8b..b1147bf 100644
--- a/base/cplusplus/test/inputs/json/misc/9929c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/9929c.json/default/quicktype.hpp
@@ -709,6 +709,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/9ac3b.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/9ac3b.json/default/quicktype.hpp
index 87e3345..da8093d 100644
--- a/base/cplusplus/test/inputs/json/misc/9ac3b.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/9ac3b.json/default/quicktype.hpp
@@ -267,10 +267,13 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_facets(j.at("facets").get<Facets>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(j.at("previous").get<bool>());
         x.set_results(j.at("results").get<std::vector<Result>>());
diff --git a/base/cplusplus/test/inputs/json/misc/a0496.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/a0496.json/default/quicktype.hpp
index 8c785b6..426837c 100644
--- a/base/cplusplus/test/inputs/json/misc/a0496.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/a0496.json/default/quicktype.hpp
@@ -231,6 +231,7 @@ namespace quicktype {
         x.set_errors(j.at("errors").get<Errors>());
         x.set_frequency(j.at("frequency").get<std::string>());
         x.set_from_date(j.at("from_date").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_premium(j.at("premium").get<bool>());
diff --git a/base/cplusplus/test/inputs/json/misc/a1eca.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/a1eca.json/default/quicktype.hpp
index 4e05a8b..b1147bf 100644
--- a/base/cplusplus/test/inputs/json/misc/a1eca.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/a1eca.json/default/quicktype.hpp
@@ -709,6 +709,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/a3d8c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/a3d8c.json/default/quicktype.hpp
index d0130da..bc1c78f 100644
--- a/base/cplusplus/test/inputs/json/misc/a3d8c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/a3d8c.json/default/quicktype.hpp
@@ -635,6 +635,7 @@ struct adl_serializer<std::variant<int64_t, std::string>> {
 namespace quicktype {
     inline void from_json(const json & j, Top& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_item(j.at("item").get<std::string>());
     }
@@ -649,7 +650,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_average(get_stack_optional<std::string>(j, "average"));
         x.set_largest(j.at("largest").get<std::string>());
+        if (j.find("non_null") != j.end() && !j.at("non_null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_non_null(j.at("non_null").get<int64_t>());
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
         x.set_smallest(j.at("smallest").get<std::string>());
         x.set_sum(get_stack_optional<std::string>(j, "sum"));
@@ -685,11 +688,15 @@ namespace quicktype {
         x.set_field_name(j.at("fieldName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_format(j.at("format").get<Query>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
         x.set_render_type_name(j.at("renderTypeName").get<TypeName>());
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(get_stack_optional<int64_t>(j, "tableColumnId"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -786,17 +793,21 @@ namespace quicktype {
 
     inline void from_json(const json & j, View& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(j.at("category").get<std::string>());
         x.set_columns(j.at("columns").get<std::vector<Column>>());
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_display_type(j.at("displayType").get<std::string>());
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(j.at("flags").get<std::vector<std::string>>());
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(j.at("indexUpdatedAt").get<int64_t>());
         x.set_license(j.at("license").get<License>());
         x.set_license_id(j.at("licenseId").get<std::string>());
@@ -804,23 +815,32 @@ namespace quicktype {
         x.set_metadata(j.at("metadata").get<Metadata>());
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<std::string>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(j.at("publicationDate").get<int64_t>());
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<std::string>());
         x.set_query(j.at("query").get<Query>());
         x.set_rights(j.at("rights").get<std::vector<std::string>>());
         x.set_row_class(j.at("rowClass").get<std::string>());
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(j.at("rowsUpdatedAt").get<int64_t>());
         x.set_rows_updated_by(j.at("rowsUpdatedBy").get<std::string>());
         x.set_table_author(j.at("tableAuthor").get<Owner>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/a45b0.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/a45b0.json/default/quicktype.hpp
index d1fb096..0186ce1 100644
--- a/base/cplusplus/test/inputs/json/misc/a45b0.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/a45b0.json/default/quicktype.hpp
@@ -84,11 +84,16 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_country(j.at("country").get<Country>());
+        if (j.find("females") != j.end() && !j.at("females").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_females(j.at("females").get<int64_t>());
+        if (j.find("males") != j.end() && !j.at("males").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_males(j.at("males").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/ab0d1.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/ab0d1.json/default/quicktype.hpp
index d1fb096..0186ce1 100644
--- a/base/cplusplus/test/inputs/json/misc/ab0d1.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/ab0d1.json/default/quicktype.hpp
@@ -84,11 +84,16 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_country(j.at("country").get<Country>());
+        if (j.find("females") != j.end() && !j.at("females").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_females(j.at("females").get<int64_t>());
+        if (j.find("males") != j.end() && !j.at("males").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_males(j.at("males").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/abb4b.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/abb4b.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/abb4b.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/abb4b.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/ae7f0.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/ae7f0.json/default/quicktype.hpp
index 0385cde..fd89b3b 100644
--- a/base/cplusplus/test/inputs/json/misc/ae7f0.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/ae7f0.json/default/quicktype.hpp
@@ -548,8 +548,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(get_untyped(j, "distinguished"));
         x.set_domain(j.at("domain").get<Domain>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -564,6 +566,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -572,6 +575,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_untyped(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -586,6 +590,7 @@ namespace quicktype {
         x.set_suggested_sort(get_untyped(j, "suggested_sort"));
         x.set_thumbnail(j.at("thumbnail").get<std::string>());
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/af2d1.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/af2d1.json/default/quicktype.hpp
index b4b2f4e..6bac3eb 100644
--- a/base/cplusplus/test/inputs/json/misc/af2d1.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/af2d1.json/default/quicktype.hpp
@@ -498,6 +498,7 @@ namespace quicktype {
         x.set_area(j.at("area_").get<double>());
         x.set_asset_numb(j.at("asset_numb").get<std::string>());
         x.set_comments(get_stack_optional<std::string>(j, "comments"));
+        if (j.find("condition") != j.end() && !j.at("condition").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_condition(j.at("condition").get<int64_t>());
         x.set_constructi(get_stack_optional<std::string>(j, "constructi"));
         x.set_createdate(get_untyped(j, "createdate"));
@@ -508,18 +509,22 @@ namespace quicktype {
         x.set_file_numbe(get_stack_optional<std::string>(j, "file_numbe"));
         x.set_folder_num(get_stack_optional<std::string>(j, "folder_num"));
         x.set_funding_ba(get_stack_optional<FundingBa>(j, "funding_ba"));
+        if (j.find("historic_c") != j.end() && !j.at("historic_c").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_historic_c(j.at("historic_c").get<int64_t>());
         x.set_inspection(j.at("inspection").get<std::string>());
         x.set_inspectors(get_untyped(j, "inspectors"));
         x.set_last_updat(get_untyped(j, "last_updat"));
         x.set_level_accu(get_stack_optional<LevelAccu>(j, "level_accu"));
         x.set_material(j.at("material").get<Material>());
+        if (j.find("mi_prinx") != j.end() && !j.at("mi_prinx").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mi_prinx(j.at("mi_prinx").get<int64_t>());
         x.set_mi_symbolo(j.at("mi_symbolo").get<MiSymbolo>());
+        if (j.find("number_lan") != j.end() && !j.at("number_lan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_lan(j.at("number_lan").get<int64_t>());
         x.set_owner(get_stack_optional<std::string>(j, "owner"));
         x.set_positional(get_stack_optional<LevelAccu>(j, "positional"));
         x.set_project_nu(get_stack_optional<std::string>(j, "project_nu"));
+        if (j.find("rec_id") != j.end() && !j.at("rec_id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rec_id(j.at("rec_id").get<int64_t>());
         x.set_record_cre(get_stack_optional<std::string>(j, "record_cre"));
         x.set_shape_area(j.at("shape_area").get<double>());
@@ -598,6 +603,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_crs(j.at("crs").get<Crs>());
         x.set_features(j.at("features").get<std::vector<Feature>>());
+        if (j.find("totalFeatures") != j.end() && !j.at("totalFeatures").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_features(j.at("totalFeatures").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/b6f2c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/b6f2c.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/b6f2c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/b6f2c.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/bb1ec.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/bb1ec.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/bb1ec.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/bb1ec.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/be234.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/be234.json/default/quicktype.hpp
index 3c100eb..b7e6089 100644
--- a/base/cplusplus/test/inputs/json/misc/be234.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/be234.json/default/quicktype.hpp
@@ -783,16 +783,20 @@ namespace quicktype {
     inline void from_json(const json & j, Oembed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_description(j.at("description").get<std::string>());
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_html(j.at("html").get<std::string>());
         x.set_provider_name(j.at("provider_name").get<std::string>());
         x.set_provider_url(j.at("provider_url").get<std::string>());
+        if (j.find("thumbnail_height") != j.end() && !j.at("thumbnail_height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_height(j.at("thumbnail_height").get<int64_t>());
         x.set_thumbnail_url(j.at("thumbnail_url").get<std::string>());
+        if (j.find("thumbnail_width") != j.end() && !j.at("thumbnail_width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_width(j.at("thumbnail_width").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_type(j.at("type").get<std::string>());
         x.set_version(j.at("version").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -827,8 +831,10 @@ namespace quicktype {
     inline void from_json(const json & j, MediaEmbed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_content(get_stack_optional<std::string>(j, "content"));
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(get_stack_optional<int64_t>(j, "height"));
         x.set_scrolling(get_stack_optional<bool>(j, "scrolling"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -842,8 +848,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -925,8 +933,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(get_stack_optional<std::string>(j, "distinguished"));
         x.set_domain(j.at("domain").get<Domain>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -941,6 +951,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -951,6 +962,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_stack_optional<Media>(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -964,9 +976,12 @@ namespace quicktype {
         x.set_subreddit_type(j.at("subreddit_type").get<SubredditType>());
         x.set_suggested_sort(get_untyped(j, "suggested_sort"));
         x.set_thumbnail(j.at("thumbnail").get<std::string>());
+        if (j.find("thumbnail_height") != j.end() && !j.at("thumbnail_height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_height(j.at("thumbnail_height").get<int64_t>());
+        if (j.find("thumbnail_width") != j.end() && !j.at("thumbnail_width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_width(j.at("thumbnail_width").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/c0356.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/c0356.json/default/quicktype.hpp
index 43431d4..5dd7e81 100644
--- a/base/cplusplus/test/inputs/json/misc/c0356.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/c0356.json/default/quicktype.hpp
@@ -119,6 +119,7 @@ namespace quicktype {
     inline void from_json(const json & j, Description& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_base_period(j.at("base_period").get<std::string>());
+        if (j.find("missing") != j.end() && !j.at("missing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_missing(j.at("missing").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/c3303.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/c3303.json/default/quicktype.hpp
index 3bd0d86..7801bff 100644
--- a/base/cplusplus/test/inputs/json/misc/c3303.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/c3303.json/default/quicktype.hpp
@@ -753,6 +753,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -792,6 +793,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -804,8 +806,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/c8c7e.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/c8c7e.json/default/quicktype.hpp
index a64b0f7..9e0251b 100644
--- a/base/cplusplus/test/inputs/json/misc/c8c7e.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/c8c7e.json/default/quicktype.hpp
@@ -235,9 +235,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, FluffyTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pages") != j.end() && !j.at("pages").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pages(j.at("pages").get<int64_t>());
         x.set_per_page(j.at("per_page").get<std::string>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/cda6c.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/cda6c.json/default/quicktype.hpp
index e2aaf96..1b0a562 100644
--- a/base/cplusplus/test/inputs/json/misc/cda6c.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/cda6c.json/default/quicktype.hpp
@@ -235,9 +235,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, FluffyTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pages") != j.end() && !j.at("pages").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pages(j.at("pages").get<int64_t>());
         x.set_per_page(j.at("per_page").get<std::string>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/cf0d8.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/cf0d8.json/default/quicktype.hpp
index 4e05a8b..b1147bf 100644
--- a/base/cplusplus/test/inputs/json/misc/cf0d8.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/cf0d8.json/default/quicktype.hpp
@@ -709,6 +709,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/d0908.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/d0908.json/default/quicktype.hpp
index 7e2528a..8f36a25 100644
--- a/base/cplusplus/test/inputs/json/misc/d0908.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/d0908.json/default/quicktype.hpp
@@ -75,6 +75,7 @@ namespace quicktype {
     inline void from_json(const json & j, TotalPopulation& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_date(j.at("date").get<std::string>());
+        if (j.find("population") != j.end() && !j.at("population").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_population(j.at("population").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/d23d5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/d23d5.json/default/quicktype.hpp
index 90aa62a..9f05c75 100644
--- a/base/cplusplus/test/inputs/json/misc/d23d5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/d23d5.json/default/quicktype.hpp
@@ -223,10 +223,13 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_facets(j.at("facets").get<Facets>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(j.at("next").get<std::string>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(j.at("previous").get<bool>());
         x.set_results(j.at("results").get<std::vector<Result>>());
diff --git a/base/cplusplus/test/inputs/json/misc/dbfb3.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/dbfb3.json/default/quicktype.hpp
index 2b1ccc3..d7d58a6 100644
--- a/base/cplusplus/test/inputs/json/misc/dbfb3.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/dbfb3.json/default/quicktype.hpp
@@ -714,6 +714,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/dc44f.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/dc44f.json/default/quicktype.hpp
index db901d0..0a03998 100644
--- a/base/cplusplus/test/inputs/json/misc/dc44f.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/dc44f.json/default/quicktype.hpp
@@ -421,6 +421,7 @@ namespace quicktype {
     inline void from_json(const json & j, Card& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_artist(j.at("artist").get<std::string>());
+        if (j.find("cmc") != j.end() && !j.at("cmc").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cmc(j.at("cmc").get<int64_t>());
         x.set_color_identity(get_stack_optional<std::vector<ColorIdentity>>(j, "colorIdentity"));
         x.set_colors(get_stack_optional<std::vector<Color>>(j, "colors"));
@@ -431,6 +432,7 @@ namespace quicktype {
         x.set_legalities(j.at("legalities").get<std::vector<LegalityElement>>());
         x.set_mana_cost(get_stack_optional<std::string>(j, "manaCost"));
         x.set_mci_number(get_stack_optional<std::string>(j, "mciNumber"));
+        if (j.find("multiverseid") != j.end() && !j.at("multiverseid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_multiverseid(j.at("multiverseid").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_original_text(get_stack_optional<std::string>(j, "originalText"));
@@ -488,6 +490,7 @@ namespace quicktype {
         x.set_code(j.at("code").get<std::string>());
         x.set_gatherer_code(j.at("gathererCode").get<std::string>());
         x.set_magic_cards_info_code(j.at("magicCardsInfoCode").get<std::string>());
+        if (j.find("mkm_id") != j.end() && !j.at("mkm_id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mkm_id(j.at("mkm_id").get<int64_t>());
         x.set_mkm_name(j.at("mkm_name").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/dd1ce.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/dd1ce.json/default/quicktype.hpp
index db901d0..0a03998 100644
--- a/base/cplusplus/test/inputs/json/misc/dd1ce.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/dd1ce.json/default/quicktype.hpp
@@ -421,6 +421,7 @@ namespace quicktype {
     inline void from_json(const json & j, Card& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_artist(j.at("artist").get<std::string>());
+        if (j.find("cmc") != j.end() && !j.at("cmc").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cmc(j.at("cmc").get<int64_t>());
         x.set_color_identity(get_stack_optional<std::vector<ColorIdentity>>(j, "colorIdentity"));
         x.set_colors(get_stack_optional<std::vector<Color>>(j, "colors"));
@@ -431,6 +432,7 @@ namespace quicktype {
         x.set_legalities(j.at("legalities").get<std::vector<LegalityElement>>());
         x.set_mana_cost(get_stack_optional<std::string>(j, "manaCost"));
         x.set_mci_number(get_stack_optional<std::string>(j, "mciNumber"));
+        if (j.find("multiverseid") != j.end() && !j.at("multiverseid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_multiverseid(j.at("multiverseid").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_original_text(get_stack_optional<std::string>(j, "originalText"));
@@ -488,6 +490,7 @@ namespace quicktype {
         x.set_code(j.at("code").get<std::string>());
         x.set_gatherer_code(j.at("gathererCode").get<std::string>());
         x.set_magic_cards_info_code(j.at("magicCardsInfoCode").get<std::string>());
+        if (j.find("mkm_id") != j.end() && !j.at("mkm_id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mkm_id(j.at("mkm_id").get<int64_t>());
         x.set_mkm_name(j.at("mkm_name").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/dec3a.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/dec3a.json/default/quicktype.hpp
index f8ff9f3..43baab9 100644
--- a/base/cplusplus/test/inputs/json/misc/dec3a.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/dec3a.json/default/quicktype.hpp
@@ -340,6 +340,7 @@ namespace quicktype {
     inline void from_json(const json & j, ResponseInfo& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_developer_message(j.at("developerMessage").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -351,8 +352,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Resultset& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pagesize") != j.end() && !j.at("pagesize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pagesize(j.at("pagesize").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/df957.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/df957.json/default/quicktype.hpp
index 4e05a8b..b1147bf 100644
--- a/base/cplusplus/test/inputs/json/misc/df957.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/df957.json/default/quicktype.hpp
@@ -709,6 +709,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/e0ac7.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/e0ac7.json/default/quicktype.hpp
index 5676481..ac2d0ca 100644
--- a/base/cplusplus/test/inputs/json/misc/e0ac7.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/e0ac7.json/default/quicktype.hpp
@@ -755,6 +755,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -794,6 +795,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -806,8 +808,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/e2915.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/e2915.json/default/quicktype.hpp
index bd4c1d0..c7228b8 100644
--- a/base/cplusplus/test/inputs/json/misc/e2915.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/e2915.json/default/quicktype.hpp
@@ -714,6 +714,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Query& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_created(j.at("created").get<std::string>());
         x.set_lang(j.at("lang").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/misc/e53b5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/e53b5.json/default/quicktype.hpp
index c4e54ec..d2d5507 100644
--- a/base/cplusplus/test/inputs/json/misc/e53b5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/e53b5.json/default/quicktype.hpp
@@ -235,9 +235,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, FluffyTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
+        if (j.find("pages") != j.end() && !j.at("pages").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pages(j.at("pages").get<int64_t>());
         x.set_per_page(j.at("per_page").get<std::string>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/e8a0b.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/e8a0b.json/default/quicktype.hpp
index d1fb096..0186ce1 100644
--- a/base/cplusplus/test/inputs/json/misc/e8a0b.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/e8a0b.json/default/quicktype.hpp
@@ -84,11 +84,16 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_country(j.at("country").get<Country>());
+        if (j.find("females") != j.end() && !j.at("females").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_females(j.at("females").get<int64_t>());
+        if (j.find("males") != j.end() && !j.at("males").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_males(j.at("males").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/e8b04.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/e8b04.json/default/quicktype.hpp
index 2a1cee3..0d13462 100644
--- a/base/cplusplus/test/inputs/json/misc/e8b04.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/e8b04.json/default/quicktype.hpp
@@ -1153,6 +1153,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TableColumnId& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("2819740") != j.end() && !j.at("2819740").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_the_2819740(j.at("2819740").get<int64_t>());
     }
 
@@ -1165,9 +1166,11 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_custom_values(get_stack_optional<std::vector<std::string>>(j, "customValues"));
         x.set_freeform(get_stack_optional<bool>(j, "freeform"));
+        if (j.find("includeAuto") != j.end() && !j.at("includeAuto").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_include_auto(get_stack_optional<int64_t>(j, "includeAuto"));
         x.set_metadata_operator(get_stack_optional<MetadataOperator>(j, "operator"));
         x.set_table_column_id(get_stack_optional<TableColumnId>(j, "tableColumnId"));
+        if (j.find("unifiedVersion") != j.end() && !j.at("unifiedVersion").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unified_version(get_stack_optional<int64_t>(j, "unifiedVersion"));
     }
 
@@ -1255,6 +1258,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Field& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(j.at("tableColumnId").get<int64_t>());
         x.set_type(j.at("type").get<FieldType>());
     }
@@ -1394,6 +1398,7 @@ namespace quicktype {
         x.set_display_name(j.at("displayName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("lastNotificationSeenAt") != j.end() && !j.at("lastNotificationSeenAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_last_notification_seen_at(get_stack_optional<int64_t>(j, "lastNotificationSeenAt"));
         x.set_profile_image_url_large(get_stack_optional<std::string>(j, "profileImageUrlLarge"));
         x.set_profile_image_url_medium(get_stack_optional<std::string>(j, "profileImageUrlMedium"));
@@ -1419,6 +1424,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Ratings& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("rating") != j.end() && !j.at("rating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rating(j.at("rating").get<int64_t>());
     }
 
@@ -1447,17 +1453,21 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(get_stack_optional<std::string>(j, "category"));
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_description(get_stack_optional<std::string>(j, "description"));
         x.set_display_type(get_stack_optional<DisplayType>(j, "displayType"));
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(get_stack_optional<std::vector<TopLevelFlag>>(j, "flags"));
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(get_stack_optional<int64_t>(j, "indexUpdatedAt"));
         x.set_locale(j.at("locale").get<std::string>());
         x.set_metadata(j.at("metadata").get<TopLevelMetadata>());
@@ -1465,26 +1475,36 @@ namespace quicktype {
         x.set_modifying_view_uid(get_stack_optional<ModifyingViewUid>(j, "modifyingViewUid"));
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<Provenance>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(get_stack_optional<int64_t>(j, "publicationDate"));
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<PublicationStage>());
         x.set_ratings(get_stack_optional<Ratings>(j, "ratings"));
         x.set_resource_name(get_stack_optional<std::string>(j, "resourceName"));
         x.set_rights(j.at("rights").get<std::vector<Right>>());
         x.set_row_class(get_stack_optional<std::string>(j, "rowClass"));
+        if (j.find("rowIdentifierColumnId") != j.end() && !j.at("rowIdentifierColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_row_identifier_column_id(get_stack_optional<int64_t>(j, "rowIdentifierColumnId"));
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(get_stack_optional<int64_t>(j, "rowsUpdatedAt"));
         x.set_rows_updated_by(get_stack_optional<RowsUpdatedBy>(j, "rowsUpdatedBy"));
         x.set_table_author(j.at("tableAuthor").get<TableAuthor>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
         x.set_tags(get_stack_optional<std::vector<std::string>>(j, "tags"));
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<ViewType>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/f22f5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/f22f5.json/default/quicktype.hpp
index 8a96eee..f9346ac 100644
--- a/base/cplusplus/test/inputs/json/misc/f22f5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/f22f5.json/default/quicktype.hpp
@@ -543,8 +543,10 @@ namespace quicktype {
         x.set_created_utc(j.at("created_utc").get<double>());
         x.set_distinguished(get_untyped(j, "distinguished"));
         x.set_domain(j.at("domain").get<std::string>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -559,6 +561,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -567,6 +570,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_untyped(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -581,6 +585,7 @@ namespace quicktype {
         x.set_suggested_sort(get_untyped(j, "suggested_sort"));
         x.set_thumbnail(j.at("thumbnail").get<std::string>());
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/misc/f3edf.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/f3edf.json/default/quicktype.hpp
index d1fb096..0186ce1 100644
--- a/base/cplusplus/test/inputs/json/misc/f3edf.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/f3edf.json/default/quicktype.hpp
@@ -84,11 +84,16 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_country(j.at("country").get<Country>());
+        if (j.find("females") != j.end() && !j.at("females").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_females(j.at("females").get<int64_t>());
+        if (j.find("males") != j.end() && !j.at("males").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_males(j.at("males").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/f466a.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/f466a.json/default/quicktype.hpp
index d1fb096..0186ce1 100644
--- a/base/cplusplus/test/inputs/json/misc/f466a.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/f466a.json/default/quicktype.hpp
@@ -84,11 +84,16 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_country(j.at("country").get<Country>());
+        if (j.find("females") != j.end() && !j.at("females").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_females(j.at("females").get<int64_t>());
+        if (j.find("males") != j.end() && !j.at("males").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_males(j.at("males").get<int64_t>());
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/f6a65.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/f6a65.json/default/quicktype.hpp
index fcd28e8..3152015 100644
--- a/base/cplusplus/test/inputs/json/misc/f6a65.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/f6a65.json/default/quicktype.hpp
@@ -760,6 +760,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<Images>());
         x.set_import_datetime(j.at("import_datetime").get<std::string>());
+        if (j.find("is_indexable") != j.end() && !j.at("is_indexable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is_indexable(j.at("is_indexable").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_slug(j.at("slug").get<std::string>());
@@ -799,6 +800,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_msg(j.at("msg").get<std::string>());
         x.set_response_id(j.at("response_id").get<std::string>());
+        if (j.find("status") != j.end() && !j.at("status").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_status(j.at("status").get<int64_t>());
     }
 
@@ -811,8 +813,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pagination& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/f74d5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/f74d5.json/default/quicktype.hpp
index d51bacd..cec4a7b 100644
--- a/base/cplusplus/test/inputs/json/misc/f74d5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/f74d5.json/default/quicktype.hpp
@@ -635,6 +635,7 @@ struct adl_serializer<std::variant<int64_t, std::string>> {
 namespace quicktype {
     inline void from_json(const json & j, Top& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_item(j.at("item").get<std::string>());
     }
@@ -649,7 +650,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_average(get_stack_optional<std::string>(j, "average"));
         x.set_largest(j.at("largest").get<std::string>());
+        if (j.find("non_null") != j.end() && !j.at("non_null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_non_null(j.at("non_null").get<int64_t>());
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
         x.set_smallest(j.at("smallest").get<std::string>());
         x.set_sum(get_stack_optional<std::string>(j, "sum"));
@@ -685,11 +688,15 @@ namespace quicktype {
         x.set_field_name(j.at("fieldName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_format(j.at("format").get<Query>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
         x.set_render_type_name(j.at("renderTypeName").get<TypeName>());
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(get_stack_optional<int64_t>(j, "tableColumnId"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -786,17 +793,21 @@ namespace quicktype {
 
     inline void from_json(const json & j, View& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(j.at("category").get<std::string>());
         x.set_columns(j.at("columns").get<std::vector<Column>>());
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_display_type(j.at("displayType").get<std::string>());
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(j.at("flags").get<std::vector<std::string>>());
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(j.at("indexUpdatedAt").get<int64_t>());
         x.set_license(j.at("license").get<License>());
         x.set_license_id(j.at("licenseId").get<std::string>());
@@ -804,23 +815,32 @@ namespace quicktype {
         x.set_metadata(j.at("metadata").get<Metadata>());
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<std::string>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(j.at("publicationDate").get<int64_t>());
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<std::string>());
         x.set_query(j.at("query").get<Query>());
         x.set_rights(j.at("rights").get<std::vector<std::string>>());
         x.set_row_class(j.at("rowClass").get<std::string>());
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(j.at("rowsUpdatedAt").get<int64_t>());
         x.set_rows_updated_by(j.at("rowsUpdatedBy").get<std::string>());
         x.set_table_author(j.at("tableAuthor").get<Owner>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/f974d.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/f974d.json/default/quicktype.hpp
index f1f46d7..63134f6 100644
--- a/base/cplusplus/test/inputs/json/misc/f974d.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/f974d.json/default/quicktype.hpp
@@ -72,9 +72,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("block_index") != j.end() && !j.at("block_index").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_block_index(j.at("block_index").get<int64_t>());
         x.set_hash(j.at("hash").get<std::string>());
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
+        if (j.find("time") != j.end() && !j.at("time").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_time(j.at("time").get<int64_t>());
         x.set_tx_indexes(j.at("txIndexes").get<std::vector<int64_t>>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/faff5.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/faff5.json/default/quicktype.hpp
index 272e136..d40e5fd 100644
--- a/base/cplusplus/test/inputs/json/misc/faff5.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/faff5.json/default/quicktype.hpp
@@ -74,7 +74,9 @@ namespace quicktype {
 
     inline void from_json(const json & j, Response& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("player_count") != j.end() && !j.at("player_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_player_count(j.at("player_count").get<int64_t>());
+        if (j.find("result") != j.end() && !j.at("result").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_result(j.at("result").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/misc/fcca3.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/fcca3.json/default/quicktype.hpp
index 305c047..073fe31 100644
--- a/base/cplusplus/test/inputs/json/misc/fcca3.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/fcca3.json/default/quicktype.hpp
@@ -1074,6 +1074,7 @@ struct adl_serializer<std::variant<int64_t, std::string>> {
 namespace quicktype {
     inline void from_json(const json & j, Top& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(j.at("count").get<int64_t>());
         x.set_item(j.at("item").get<std::string>());
     }
@@ -1088,7 +1089,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_average(get_stack_optional<std::string>(j, "average"));
         x.set_largest(j.at("largest").get<std::string>());
+        if (j.find("non_null") != j.end() && !j.at("non_null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_non_null(j.at("non_null").get<int64_t>());
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
         x.set_smallest(j.at("smallest").get<std::string>());
         x.set_sum(get_stack_optional<std::string>(j, "sum"));
@@ -1128,11 +1131,15 @@ namespace quicktype {
         x.set_field_name(j.at("fieldName").get<std::string>());
         x.set_flags(get_stack_optional<std::vector<std::string>>(j, "flags"));
         x.set_format(j.at("format").get<Format>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
         x.set_render_type_name(j.at("renderTypeName").get<TypeName>());
+        if (j.find("tableColumnId") != j.end() && !j.at("tableColumnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_column_id(get_stack_optional<int64_t>(j, "tableColumnId"));
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(get_stack_optional<int64_t>(j, "width"));
     }
 
@@ -1256,6 +1263,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TableColumnId& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("703610") != j.end() && !j.at("703610").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_the_703610(j.at("703610").get<int64_t>());
     }
 
@@ -1295,6 +1303,7 @@ namespace quicktype {
     inline void from_json(const json & j, FilterConditionMetadata& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_advanced(j.at("advanced").get<bool>());
+        if (j.find("unifiedVersion") != j.end() && !j.at("unifiedVersion").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unified_version(j.at("unifiedVersion").get<int64_t>());
     }
 
@@ -1412,6 +1421,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Expression& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("columnId") != j.end() && !j.at("columnId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_column_id(j.at("columnId").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
     }
@@ -1447,40 +1457,53 @@ namespace quicktype {
     inline void from_json(const json & j, View& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_attribution(j.at("attribution").get<std::string>());
+        if (j.find("averageRating") != j.end() && !j.at("averageRating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_average_rating(j.at("averageRating").get<int64_t>());
         x.set_category(j.at("category").get<std::string>());
         x.set_columns(j.at("columns").get<std::vector<Column>>());
+        if (j.find("createdAt") != j.end() && !j.at("createdAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_at(j.at("createdAt").get<int64_t>());
         x.set_description(j.at("description").get<std::string>());
         x.set_display_type(j.at("displayType").get<std::string>());
+        if (j.find("downloadCount") != j.end() && !j.at("downloadCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_download_count(j.at("downloadCount").get<int64_t>());
         x.set_flags(j.at("flags").get<std::vector<std::string>>());
         x.set_grants(j.at("grants").get<std::vector<Grant>>());
         x.set_hide_from_catalog(j.at("hideFromCatalog").get<bool>());
         x.set_hide_from_data_json(j.at("hideFromDataJson").get<bool>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("indexUpdatedAt") != j.end() && !j.at("indexUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_index_updated_at(j.at("indexUpdatedAt").get<int64_t>());
         x.set_locale(j.at("locale").get<std::string>());
         x.set_metadata(j.at("metadata").get<ViewMetadata>());
         x.set_name(j.at("name").get<std::string>());
         x.set_new_backend(j.at("newBackend").get<bool>());
+        if (j.find("numberOfComments") != j.end() && !j.at("numberOfComments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number_of_comments(j.at("numberOfComments").get<int64_t>());
+        if (j.find("oid") != j.end() && !j.at("oid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oid(j.at("oid").get<int64_t>());
         x.set_owner(j.at("owner").get<Owner>());
         x.set_provenance(j.at("provenance").get<std::string>());
         x.set_publication_append_enabled(j.at("publicationAppendEnabled").get<bool>());
+        if (j.find("publicationDate") != j.end() && !j.at("publicationDate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_date(j.at("publicationDate").get<int64_t>());
+        if (j.find("publicationGroup") != j.end() && !j.at("publicationGroup").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_publication_group(j.at("publicationGroup").get<int64_t>());
         x.set_publication_stage(j.at("publicationStage").get<std::string>());
         x.set_query(j.at("query").get<Query>());
         x.set_rights(j.at("rights").get<std::vector<std::string>>());
+        if (j.find("rowsUpdatedAt") != j.end() && !j.at("rowsUpdatedAt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rows_updated_at(j.at("rowsUpdatedAt").get<int64_t>());
         x.set_rows_updated_by(j.at("rowsUpdatedBy").get<std::string>());
         x.set_table_author(j.at("tableAuthor").get<Owner>());
+        if (j.find("tableId") != j.end() && !j.at("tableId").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_table_id(j.at("tableId").get<int64_t>());
         x.set_tags(j.at("tags").get<std::vector<std::string>>());
+        if (j.find("totalTimesRated") != j.end() && !j.at("totalTimesRated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_times_rated(j.at("totalTimesRated").get<int64_t>());
+        if (j.find("viewCount") != j.end() && !j.at("viewCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_count(j.at("viewCount").get<int64_t>());
+        if (j.find("viewLastModified") != j.end() && !j.at("viewLastModified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_view_last_modified(j.at("viewLastModified").get<int64_t>());
         x.set_view_type(j.at("viewType").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/misc/fd329.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/misc/fd329.json/default/quicktype.hpp
index 524bc15..caa9af8 100644
--- a/base/cplusplus/test/inputs/json/misc/fd329.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/misc/fd329.json/default/quicktype.hpp
@@ -124,6 +124,7 @@ namespace quicktype {
     inline void from_json(const json & j, Description& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_base_period(j.at("base_period").get<std::string>());
+        if (j.find("missing") != j.end() && !j.at("missing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_missing(j.at("missing").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_units(j.at("units").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/priority/bug427.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/bug427.json/default/quicktype.hpp
index 8a6657b..bc35dd3 100644
--- a/base/cplusplus/test/inputs/json/priority/bug427.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/bug427.json/default/quicktype.hpp
@@ -2763,8 +2763,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("character") != j.end() && !j.at("character").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_character(j.at("character").get<int64_t>());
         x.set_file_name(j.at("fileName").get<FileName>());
+        if (j.find("line") != j.end() && !j.at("line").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_line(j.at("line").get<int64_t>());
     }
 
@@ -2792,6 +2794,7 @@ namespace quicktype {
     inline void from_json(const json & j, Group& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_children(j.at("children").get<std::vector<int64_t>>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
     }
@@ -2847,7 +2850,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<TentacledComment>(j, "comment"));
         x.set_flags(j.at("flags").get<TentacledFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<ParameterKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -2884,7 +2889,9 @@ namespace quicktype {
     inline void from_json(const json & j, IndexSignatureElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -2921,7 +2928,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<FluffyComment>(j, "comment"));
         x.set_flags(j.at("flags").get<FluffyFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<PurpleKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -2948,7 +2957,9 @@ namespace quicktype {
         x.set_default_value(get_stack_optional<std::string>(j, "defaultValue"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
         x.set_groups(get_stack_optional<std::vector<Group>>(j, "groups"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -2982,7 +2993,9 @@ namespace quicktype {
         x.set_children(j.at("children").get<std::vector<GetSignature>>());
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
         x.set_groups(j.at("groups").get<std::vector<Group>>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3017,7 +3030,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<PurpleComment>(j, "comment"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<SignatureKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3060,7 +3075,9 @@ namespace quicktype {
         x.set_comment(get_stack_optional<PurpleComment>(j, "comment"));
         x.set_default_value(get_stack_optional<std::string>(j, "defaultValue"));
         x.set_flags(j.at("flags").get<PurpleFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<PurpleKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3136,6 +3153,7 @@ namespace quicktype {
     inline void from_json(const json & j, ExtendedBy& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_constraint(get_heap_optional<ExtendedBy>(j, "constraint"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(get_stack_optional<int64_t>(j, "id"));
         x.set_name(j.at("name").get<std::string>());
         x.set_type(j.at("type").get<TypeEnum>());
@@ -3169,6 +3187,7 @@ namespace quicktype {
         x.set_declaration(get_heap_optional<GetSignature>(j, "declaration"));
         x.set_element_type(get_stack_optional<ElementType>(j, "elementType"));
         x.set_elements(get_stack_optional<std::vector<ExtendedBy>>(j, "elements"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(get_stack_optional<int64_t>(j, "id"));
         x.set_name(get_stack_optional<std::string>(j, "name"));
         x.set_type(j.at("type").get<TypeEnum>());
@@ -3191,7 +3210,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<TentacledComment>(j, "comment"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<ParameterKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3213,9 +3234,11 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<StickyComment>(j, "comment"));
         x.set_flags(j.at("flags").get<IndigoFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_implementation_of(get_heap_optional<ExtendedBy>(j, "implementationOf"));
         x.set_inherited_from(get_heap_optional<ExtendedBy>(j, "inheritedFrom"));
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<SignatureKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3261,7 +3284,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<FluffyComment>(j, "comment"));
         x.set_flags(j.at("flags").get<FluffyFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<PurpleKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3296,7 +3321,9 @@ namespace quicktype {
     inline void from_json(const json & j, IndexSignature& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3331,7 +3358,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<FluffyComment>(j, "comment"));
         x.set_flags(j.at("flags").get<FluffyFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3355,7 +3384,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<IndigoComment>(j, "comment"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<SignatureKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3380,8 +3411,10 @@ namespace quicktype {
         x.set_children(get_stack_optional<std::vector<StickyChild>>(j, "children"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
         x.set_groups(get_stack_optional<std::vector<Group>>(j, "groups"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_index_signature(get_stack_optional<IndexSignature>(j, "indexSignature"));
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3423,6 +3456,7 @@ namespace quicktype {
         x.set_declaration(get_stack_optional<FluffyDeclaration>(j, "declaration"));
         x.set_element_type(get_heap_optional<ExtendedBy>(j, "elementType"));
         x.set_elements(get_stack_optional<std::vector<ElementType>>(j, "elements"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(get_stack_optional<int64_t>(j, "id"));
         x.set_name(get_stack_optional<std::string>(j, "name"));
         x.set_type(j.at("type").get<TypeEnum>());
@@ -3451,9 +3485,11 @@ namespace quicktype {
         x.set_flags(j.at("flags").get<StickyFlags>());
         x.set_get_signature(get_heap_optional<GetSignature>(j, "getSignature"));
         x.set_groups(get_stack_optional<std::vector<Group>>(j, "groups"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_implementation_of(get_heap_optional<ExtendedBy>(j, "implementationOf"));
         x.set_inherited_from(get_heap_optional<ExtendedBy>(j, "inheritedFrom"));
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<PurpleKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3512,7 +3548,9 @@ namespace quicktype {
         x.set_comment(j.at("comment").get<FluffyComment>());
         x.set_default_value(get_stack_optional<std::string>(j, "defaultValue"));
         x.set_flags(j.at("flags").get<FluffyFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<PurpleKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3538,8 +3576,10 @@ namespace quicktype {
         x.set_children(get_stack_optional<std::vector<IndigoChild>>(j, "children"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
         x.set_groups(get_stack_optional<std::vector<Group>>(j, "groups"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_index_signature(get_heap_optional<IndexSignatureElement>(j, "indexSignature"));
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3565,6 +3605,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_declaration(get_stack_optional<TentacledDeclaration>(j, "declaration"));
         x.set_element_type(get_stack_optional<ElementType>(j, "elementType"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(get_stack_optional<int64_t>(j, "id"));
         x.set_name(get_stack_optional<std::string>(j, "name"));
         x.set_type(j.at("type").get<TypeEnum>());
@@ -3586,7 +3627,9 @@ namespace quicktype {
         x.set_comment(get_stack_optional<TentacledComment>(j, "comment"));
         x.set_default_value(get_stack_optional<std::string>(j, "defaultValue"));
         x.set_flags(j.at("flags").get<TentacledFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<ParameterKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3610,6 +3653,7 @@ namespace quicktype {
     inline void from_json(const json & j, CunningType& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_declaration(get_stack_optional<PurpleDeclaration>(j, "declaration"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(get_stack_optional<int64_t>(j, "id"));
         x.set_name(get_stack_optional<Name>(j, "name"));
         x.set_type(j.at("type").get<TypeEnum>());
@@ -3629,7 +3673,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(j.at("comment").get<StickyComment>());
         x.set_flags(j.at("flags").get<IndigoFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<SignatureKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3656,7 +3702,9 @@ namespace quicktype {
         x.set_children(get_stack_optional<std::vector<GetSignature>>(j, "children"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
         x.set_groups(get_stack_optional<std::vector<Group>>(j, "groups"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3694,7 +3742,9 @@ namespace quicktype {
     inline void from_json(const json & j, IndecentChild& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_flags(j.at("flags").get<FluffyFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<PurpleKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3718,7 +3768,9 @@ namespace quicktype {
         x.set_children(get_stack_optional<std::vector<IndecentChild>>(j, "children"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
         x.set_groups(get_stack_optional<std::vector<Group>>(j, "groups"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3756,6 +3808,7 @@ namespace quicktype {
         x.set_declaration(get_stack_optional<StickyDeclaration>(j, "declaration"));
         x.set_element_type(get_stack_optional<ElementType>(j, "elementType"));
         x.set_elements(get_stack_optional<std::vector<ExtendedBy>>(j, "elements"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(get_stack_optional<int64_t>(j, "id"));
         x.set_name(get_stack_optional<std::string>(j, "name"));
         x.set_type(j.at("type").get<TypeEnum>());
@@ -3779,6 +3832,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, MischievousType& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(get_stack_optional<int64_t>(j, "id"));
         x.set_name(get_stack_optional<Name>(j, "name"));
         x.set_target(get_stack_optional<ElementType>(j, "target"));
@@ -3799,7 +3853,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_comment(get_stack_optional<PurpleComment>(j, "comment"));
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
@@ -3826,9 +3882,11 @@ namespace quicktype {
         x.set_extended_types(get_stack_optional<std::vector<ExtendedBy>>(j, "extendedTypes"));
         x.set_flags(j.at("flags").get<IndecentFlags>());
         x.set_groups(get_stack_optional<std::vector<Group>>(j, "groups"));
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_implemented_by(get_stack_optional<std::vector<ExtendedBy>>(j, "implementedBy"));
         x.set_implemented_types(get_stack_optional<std::vector<ExtendedBy>>(j, "implementedTypes"));
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<FluffyKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3877,7 +3935,9 @@ namespace quicktype {
         x.set_comment(get_stack_optional<IndecentComment>(j, "comment"));
         x.set_flags(j.at("flags").get<PurpleFlags>());
         x.set_groups(j.at("groups").get<std::vector<Group>>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_kind_string(j.at("kindString").get<TentacledKindString>());
         x.set_name(j.at("name").get<std::string>());
@@ -3904,7 +3964,9 @@ namespace quicktype {
         x.set_children(j.at("children").get<std::vector<TopLevelChild>>());
         x.set_flags(j.at("flags").get<GetSignatureFlags>());
         x.set_groups(j.at("groups").get<std::vector<Group>>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
+        if (j.find("kind") != j.end() && !j.at("kind").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kind(j.at("kind").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
     }
diff --git a/base/cplusplus/test/inputs/json/priority/bug790.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/bug790.json/default/quicktype.hpp
index 03d344b..7bc8483 100644
--- a/base/cplusplus/test/inputs/json/priority/bug790.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/bug790.json/default/quicktype.hpp
@@ -88,12 +88,17 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_children_data(j.at("children_data").get<std::vector<TopLevel>>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_is_active(j.at("is_active").get<bool>());
+        if (j.find("level") != j.end() && !j.at("level").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_level(j.at("level").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("parent_id") != j.end() && !j.at("parent_id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_parent_id(j.at("parent_id").get<int64_t>());
+        if (j.find("position") != j.end() && !j.at("position").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_position(j.at("position").get<int64_t>());
+        if (j.find("product_count") != j.end() && !j.at("product_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_product_count(j.at("product_count").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/bug855-short.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/bug855-short.json/default/quicktype.hpp
index 48f92a6..a2ab77a 100644
--- a/base/cplusplus/test/inputs/json/priority/bug855-short.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/bug855-short.json/default/quicktype.hpp
@@ -77,7 +77,9 @@ namespace quicktype {
         x.set_channel_id(j.at("channel_id").get<std::string>());
         x.set_channel_name(j.at("channel_name").get<std::string>());
         x.set_code(j.at("code").get<std::string>());
+        if (j.find("emoticon_set") != j.end() && !j.at("emoticon_set").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_emoticon_set(j.at("emoticon_set").get<int64_t>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/bug863.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/bug863.json/default/quicktype.hpp
index 111ff86..0cfe9da 100644
--- a/base/cplusplus/test/inputs/json/priority/bug863.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/bug863.json/default/quicktype.hpp
@@ -418,20 +418,27 @@ struct adl_serializer<std::variant<std::vector<quicktype::PurpleTopLevel>, quick
 namespace quicktype {
     inline void from_json(const json & j, PurpleTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("ALIENLEVEL") != j.end() && !j.at("ALIENLEVEL").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_alienlevel(j.at("ALIENLEVEL").get<int64_t>());
         x.set_breed(j.at("BREED").get<Breed>());
+        if (j.find("CHAR_DIMENSION") != j.end() && !j.at("CHAR_DIMENSION").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_char_dimension(j.at("CHAR_DIMENSION").get<int64_t>());
+        if (j.find("CHAR_INSTANCE") != j.end() && !j.at("CHAR_INSTANCE").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_char_instance(j.at("CHAR_INSTANCE").get<int64_t>());
         x.set_defender_rank_title(j.at("DEFENDER_RANK_TITLE").get<std::string>());
         x.set_firstname(j.at("FIRSTNAME").get<Firstname>());
+        if (j.find("HEADID") != j.end() && !j.at("HEADID").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_headid(j.at("HEADID").get<int64_t>());
         x.set_lastname(j.at("LASTNAME").get<Lastname>());
+        if (j.find("LEVELX") != j.end() && !j.at("LEVELX").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_levelx(j.at("LEVELX").get<int64_t>());
         x.set_name(j.at("NAME").get<std::string>());
         x.set_prof(j.at("PROF").get<std::string>());
         x.set_prof_title(j.at("PROF_TITLE").get<std::string>());
+        if (j.find("PVPRATING") != j.end() && !j.at("PVPRATING").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pvprating(j.at("PVPRATING").get<int64_t>());
         x.set_pvptitle(j.at("PVPTITLE").get<Pvptitle>());
+        if (j.find("RANK") != j.end() && !j.at("RANK").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rank(j.at("RANK").get<int64_t>());
         x.set_rank_title(j.at("RANK_TITLE").get<RankTitle>());
         x.set_sex(j.at("SEX").get<Sex>());
@@ -460,40 +467,68 @@ namespace quicktype {
 
     inline void from_json(const json & j, FluffyTopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("ADVENTURERCOUNT") != j.end() && !j.at("ADVENTURERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_adventurercount(j.at("ADVENTURERCOUNT").get<int64_t>());
+        if (j.find("AGENTCOUNT") != j.end() && !j.at("AGENTCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_agentcount(j.at("AGENTCOUNT").get<int64_t>());
+        if (j.find("ATROXCOUNT") != j.end() && !j.at("ATROXCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_atroxcount(j.at("ATROXCOUNT").get<int64_t>());
         x.set_avglvl(j.at("AVGLVL").get<double>());
+        if (j.find("BTCOUNT") != j.end() && !j.at("BTCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_btcount(j.at("BTCOUNT").get<int64_t>());
         x.set_description(j.at("DESCRIPTION").get<std::string>());
+        if (j.find("DOCTORCOUNT") != j.end() && !j.at("DOCTORCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_doctorcount(j.at("DOCTORCOUNT").get<int64_t>());
+        if (j.find("ENFCOUNT") != j.end() && !j.at("ENFCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_enfcount(j.at("ENFCOUNT").get<int64_t>());
+        if (j.find("ENGINEEERCOUNT") != j.end() && !j.at("ENGINEEERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_engineeercount(j.at("ENGINEEERCOUNT").get<int64_t>());
+        if (j.find("FEMALECOUNT") != j.end() && !j.at("FEMALECOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_femalecount(j.at("FEMALECOUNT").get<int64_t>());
+        if (j.find("FIXERCOUNT") != j.end() && !j.at("FIXERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fixercount(j.at("FIXERCOUNT").get<int64_t>());
         x.set_governingname(j.at("GOVERNINGNAME").get<std::string>());
         x.set_history(j.at("HISTORY").get<std::string>());
+        if (j.find("KEEPERCOUNT") != j.end() && !j.at("KEEPERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_keepercount(j.at("KEEPERCOUNT").get<int64_t>());
+        if (j.find("MACOUNT") != j.end() && !j.at("MACOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_macount(j.at("MACOUNT").get<int64_t>());
+        if (j.find("MALECOUNT") != j.end() && !j.at("MALECOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_malecount(j.at("MALECOUNT").get<int64_t>());
+        if (j.find("MAXLVL") != j.end() && !j.at("MAXLVL").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_maxlvl(j.at("MAXLVL").get<int64_t>());
+        if (j.find("METACOUNT") != j.end() && !j.at("METACOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_metacount(j.at("METACOUNT").get<int64_t>());
+        if (j.find("MINLVL") != j.end() && !j.at("MINLVL").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_minlvl(j.at("MINLVL").get<int64_t>());
+        if (j.find("MONSTERCOUNT") != j.end() && !j.at("MONSTERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_monstercount(j.at("MONSTERCOUNT").get<int64_t>());
         x.set_name(j.at("NAME").get<std::string>());
+        if (j.find("NANOCOUNT") != j.end() && !j.at("NANOCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nanocount(j.at("NANOCOUNT").get<int64_t>());
+        if (j.find("NANORACECOUNT") != j.end() && !j.at("NANORACECOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nanoracecount(j.at("NANORACECOUNT").get<int64_t>());
+        if (j.find("NEUTERCOUNT") != j.end() && !j.at("NEUTERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_neutercount(j.at("NEUTERCOUNT").get<int64_t>());
+        if (j.find("NUMMEMBERS") != j.end() && !j.at("NUMMEMBERS").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nummembers(j.at("NUMMEMBERS").get<int64_t>());
         x.set_objective(j.at("OBJECTIVE").get<std::string>());
+        if (j.find("OPIFEXCOUNT") != j.end() && !j.at("OPIFEXCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_opifexcount(j.at("OPIFEXCOUNT").get<int64_t>());
+        if (j.find("ORG_DIMENSION") != j.end() && !j.at("ORG_DIMENSION").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_org_dimension(j.at("ORG_DIMENSION").get<int64_t>());
+        if (j.find("ORG_INSTANCE") != j.end() && !j.at("ORG_INSTANCE").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_org_instance(j.at("ORG_INSTANCE").get<int64_t>());
+        if (j.find("SHADECOUNT") != j.end() && !j.at("SHADECOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_shadecount(j.at("SHADECOUNT").get<int64_t>());
+        if (j.find("SIDE") != j.end() && !j.at("SIDE").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_side(j.at("SIDE").get<int64_t>());
         x.set_side_name(j.at("SIDE_NAME").get<std::string>());
+        if (j.find("SOLIDERCOUNT") != j.end() && !j.at("SOLIDERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_solidercount(j.at("SOLIDERCOUNT").get<int64_t>());
+        if (j.find("SOLITUSCOUNT") != j.end() && !j.at("SOLITUSCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_solituscount(j.at("SOLITUSCOUNT").get<int64_t>());
+        if (j.find("TRADERCOUNT") != j.end() && !j.at("TRADERCOUNT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tradercount(j.at("TRADERCOUNT").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/coin-pairs.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/coin-pairs.json/default/quicktype.hpp
index 6b57d24..879d31f 100644
--- a/base/cplusplus/test/inputs/json/priority/coin-pairs.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/coin-pairs.json/default/quicktype.hpp
@@ -109,10 +109,14 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pair& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("decimal_places") != j.end() && !j.at("decimal_places").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_decimal_places(j.at("decimal_places").get<int64_t>());
         x.set_fee(j.at("fee").get<double>());
+        if (j.find("hidden") != j.end() && !j.at("hidden").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hidden(j.at("hidden").get<int64_t>());
+        if (j.find("max_amount") != j.end() && !j.at("max_amount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_max_amount(j.at("max_amount").get<int64_t>());
+        if (j.find("max_price") != j.end() && !j.at("max_price").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_max_price(j.at("max_price").get<int64_t>());
         x.set_min_amount(j.at("min_amount").get<double>());
         x.set_min_price(j.at("min_price").get<double>());
@@ -134,6 +138,7 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_pairs(j.at("pairs").get<std::map<std::string, Pair>>());
+        if (j.find("server_time") != j.end() && !j.at("server_time").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_server_time(j.at("server_time").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/combinations1.json/code-format-with-struct--67c848c66185/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations1.json/code-format-with-struct--67c848c66185/quicktype.hpp
index 8735814..40e4d8c 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations1.json/code-format-with-struct--67c848c66185/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations1.json/code-format-with-struct--67c848c66185/quicktype.hpp
@@ -775,6 +775,7 @@ namespace quicktype {
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
         x.caulis = get_untyped(j, "caulis");
         x.chalcus = get_untyped(j, "chalcus");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
         x.enteradenological = get_untyped(j, "enteradenological");
@@ -828,6 +829,7 @@ namespace quicktype {
     inline void from_json(const json & j, CimeliaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.catharticalness = j.at("catharticalness").get<double>();
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = j.at("Chirotherium").get<int64_t>();
         x.disdiapason = j.at("disdiapason").get<std::string>();
         x.homocerc = j.at("homocerc").get<bool>();
@@ -848,6 +850,7 @@ namespace quicktype {
         x.amidosulphonal = get_untyped(j, "amidosulphonal");
         x.benny = get_untyped(j, "Benny");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
         x.ensnare = get_untyped(j, "ensnare");
@@ -1244,6 +1247,7 @@ namespace quicktype {
         x.autobiographic = get_untyped(j, "autobiographic");
         x.berat = get_untyped(j, "berat");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
         x.disproportionably = get_untyped(j, "disproportionably");
@@ -1300,6 +1304,7 @@ namespace quicktype {
         x.assapan = j.at("assapan").get<double>();
         x.benefactorship = j.at("benefactorship").get<bool>();
         x.triseriatim = j.at("triseriatim").get<std::string>();
+        if (j.find("tubbing") != j.end() && !j.at("tubbing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.tubbing = j.at("tubbing").get<int64_t>();
         x.untrimmed = get_untyped(j, "untrimmed");
     }
@@ -1319,6 +1324,7 @@ namespace quicktype {
         x.cerograph = j.at("cerograph").get<std::vector<CerographElement>>();
         x.chemotherapeutics = j.at("chemotherapeutics").get<std::vector<ChemotherapeuticElement>>();
         x.cimelia = j.at("cimelia").get<std::vector<CimeliaElement>>();
+        if (j.find("citrated") != j.end() && !j.at("citrated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.citrated = j.at("citrated").get<int64_t>();
         x.clinodome = j.at("clinodome").get<std::vector<Clinodome>>();
         x.coadjust = j.at("coadjust").get<std::vector<CoadjustElement>>();
diff --git a/base/cplusplus/test/inputs/json/priority/combinations1.json/const-style-east-const--0048a2a7a881/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations1.json/const-style-east-const--0048a2a7a881/quicktype.hpp
index 237e851..412aa34 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations1.json/const-style-east-const--0048a2a7a881/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations1.json/const-style-east-const--0048a2a7a881/quicktype.hpp
@@ -2015,6 +2015,7 @@ namespace quicktype {
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_caulis(get_untyped(j, "caulis"));
         x.set_chalcus(get_untyped(j, "chalcus"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_enteradenological(get_untyped(j, "enteradenological"));
@@ -2068,6 +2069,7 @@ namespace quicktype {
     inline void from_json(json const & j, CimeliaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -2088,6 +2090,7 @@ namespace quicktype {
         x.set_amidosulphonal(get_untyped(j, "amidosulphonal"));
         x.set_benny(get_untyped(j, "Benny"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_ensnare(get_untyped(j, "ensnare"));
@@ -2484,6 +2487,7 @@ namespace quicktype {
         x.set_autobiographic(get_untyped(j, "autobiographic"));
         x.set_berat(get_untyped(j, "berat"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_disproportionably(get_untyped(j, "disproportionably"));
@@ -2540,6 +2544,7 @@ namespace quicktype {
         x.set_assapan(j.at("assapan").get<double>());
         x.set_benefactorship(j.at("benefactorship").get<bool>());
         x.set_triseriatim(j.at("triseriatim").get<std::string>());
+        if (j.find("tubbing") != j.end() && !j.at("tubbing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tubbing(j.at("tubbing").get<int64_t>());
         x.set_untrimmed(get_untyped(j, "untrimmed"));
     }
@@ -2559,6 +2564,7 @@ namespace quicktype {
         x.set_cerograph(j.at("cerograph").get<std::vector<CerographElement>>());
         x.set_chemotherapeutics(j.at("chemotherapeutics").get<std::vector<ChemotherapeuticElement>>());
         x.set_cimelia(j.at("cimelia").get<std::vector<CimeliaElement>>());
+        if (j.find("citrated") != j.end() && !j.at("citrated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_citrated(j.at("citrated").get<int64_t>());
         x.set_clinodome(j.at("clinodome").get<std::vector<Clinodome>>());
         x.set_coadjust(j.at("coadjust").get<std::vector<CoadjustElement>>());
diff --git a/base/cplusplus/test/inputs/json/priority/combinations1.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations1.json/default/quicktype.hpp
index 37097f3..be68f7f 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations1.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations1.json/default/quicktype.hpp
@@ -2015,6 +2015,7 @@ namespace quicktype {
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_caulis(get_untyped(j, "caulis"));
         x.set_chalcus(get_untyped(j, "chalcus"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_enteradenological(get_untyped(j, "enteradenological"));
@@ -2068,6 +2069,7 @@ namespace quicktype {
     inline void from_json(const json & j, CimeliaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -2088,6 +2090,7 @@ namespace quicktype {
         x.set_amidosulphonal(get_untyped(j, "amidosulphonal"));
         x.set_benny(get_untyped(j, "Benny"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_ensnare(get_untyped(j, "ensnare"));
@@ -2484,6 +2487,7 @@ namespace quicktype {
         x.set_autobiographic(get_untyped(j, "autobiographic"));
         x.set_berat(get_untyped(j, "berat"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_disproportionably(get_untyped(j, "disproportionably"));
@@ -2540,6 +2544,7 @@ namespace quicktype {
         x.set_assapan(j.at("assapan").get<double>());
         x.set_benefactorship(j.at("benefactorship").get<bool>());
         x.set_triseriatim(j.at("triseriatim").get<std::string>());
+        if (j.find("tubbing") != j.end() && !j.at("tubbing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tubbing(j.at("tubbing").get<int64_t>());
         x.set_untrimmed(get_untyped(j, "untrimmed"));
     }
@@ -2559,6 +2564,7 @@ namespace quicktype {
         x.set_cerograph(j.at("cerograph").get<std::vector<CerographElement>>());
         x.set_chemotherapeutics(j.at("chemotherapeutics").get<std::vector<ChemotherapeuticElement>>());
         x.set_cimelia(j.at("cimelia").get<std::vector<CimeliaElement>>());
+        if (j.find("citrated") != j.end() && !j.at("citrated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_citrated(j.at("citrated").get<int64_t>());
         x.set_clinodome(j.at("clinodome").get<std::vector<Clinodome>>());
         x.set_coadjust(j.at("coadjust").get<std::vector<CoadjustElement>>());
diff --git a/base/cplusplus/test/inputs/json/priority/combinations2.json/code-format-with-struct--67c848c66185/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations2.json/code-format-with-struct--67c848c66185/quicktype.hpp
index d3724ac..04e52f6 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations2.json/code-format-with-struct--67c848c66185/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations2.json/code-format-with-struct--67c848c66185/quicktype.hpp
@@ -719,6 +719,7 @@ namespace quicktype {
     inline void from_json(const json & j, Rebecca& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.catharticalness = j.at("catharticalness").get<double>();
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = j.at("Chirotherium").get<int64_t>();
         x.disdiapason = j.at("disdiapason").get<std::string>();
         x.homocerc = j.at("homocerc").get<bool>();
@@ -736,30 +737,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, Amphithyron& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("akroasis") != j.end() && !j.at("akroasis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.akroasis = get_stack_optional<int64_t>(j, "akroasis");
+        if (j.find("antiphonical") != j.end() && !j.at("antiphonical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.antiphonical = get_stack_optional<int64_t>(j, "antiphonical");
+        if (j.find("basebred") != j.end() && !j.at("basebred").is_number_integer()) throw std::runtime_error("Expected integer");
         x.basebred = get_stack_optional<int64_t>(j, "basebred");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("conductometric") != j.end() && !j.at("conductometric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.conductometric = get_stack_optional<int64_t>(j, "conductometric");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("ensilation") != j.end() && !j.at("ensilation").is_number_integer()) throw std::runtime_error("Expected integer");
         x.ensilation = get_stack_optional<int64_t>(j, "ensilation");
+        if (j.find("eyebolt") != j.end() && !j.at("eyebolt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.eyebolt = get_stack_optional<int64_t>(j, "eyebolt");
+        if (j.find("fistulated") != j.end() && !j.at("fistulated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.fistulated = get_stack_optional<int64_t>(j, "fistulated");
+        if (j.find("heteropod") != j.end() && !j.at("heteropod").is_number_integer()) throw std::runtime_error("Expected integer");
         x.heteropod = get_stack_optional<int64_t>(j, "heteropod");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("Juniperus") != j.end() && !j.at("Juniperus").is_number_integer()) throw std::runtime_error("Expected integer");
         x.juniperus = get_stack_optional<int64_t>(j, "Juniperus");
+        if (j.find("labyrinthically") != j.end() && !j.at("labyrinthically").is_number_integer()) throw std::runtime_error("Expected integer");
         x.labyrinthically = get_stack_optional<int64_t>(j, "labyrinthically");
+        if (j.find("martyrization") != j.end() && !j.at("martyrization").is_number_integer()) throw std::runtime_error("Expected integer");
         x.martyrization = get_stack_optional<int64_t>(j, "martyrization");
+        if (j.find("mispolicy") != j.end() && !j.at("mispolicy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.mispolicy = get_stack_optional<int64_t>(j, "mispolicy");
+        if (j.find("multipara") != j.end() && !j.at("multipara").is_number_integer()) throw std::runtime_error("Expected integer");
         x.multipara = get_stack_optional<int64_t>(j, "multipara");
+        if (j.find("Nazirite") != j.end() && !j.at("Nazirite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.nazirite = get_stack_optional<int64_t>(j, "Nazirite");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("possessorial") != j.end() && !j.at("possessorial").is_number_integer()) throw std::runtime_error("Expected integer");
         x.possessorial = get_stack_optional<int64_t>(j, "possessorial");
+        if (j.find("shamed") != j.end() && !j.at("shamed").is_number_integer()) throw std::runtime_error("Expected integer");
         x.shamed = get_stack_optional<int64_t>(j, "shamed");
+        if (j.find("shelfworn") != j.end() && !j.at("shelfworn").is_number_integer()) throw std::runtime_error("Expected integer");
         x.shelfworn = get_stack_optional<int64_t>(j, "shelfworn");
+        if (j.find("stagnum") != j.end() && !j.at("stagnum").is_number_integer()) throw std::runtime_error("Expected integer");
         x.stagnum = get_stack_optional<int64_t>(j, "stagnum");
+        if (j.find("Those") != j.end() && !j.at("Those").is_number_integer()) throw std::runtime_error("Expected integer");
         x.those = get_stack_optional<int64_t>(j, "Those");
+        if (j.find("undecimal") != j.end() && !j.at("undecimal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.undecimal = get_stack_optional<int64_t>(j, "undecimal");
     }
 
@@ -938,30 +960,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, DiscordiaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Altaic") != j.end() && !j.at("Altaic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.altaic = get_stack_optional<int64_t>(j, "Altaic");
+        if (j.find("amoristic") != j.end() && !j.at("amoristic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.amoristic = get_stack_optional<int64_t>(j, "amoristic");
+        if (j.find("blennophthalmia") != j.end() && !j.at("blennophthalmia").is_number_integer()) throw std::runtime_error("Expected integer");
         x.blennophthalmia = get_stack_optional<int64_t>(j, "blennophthalmia");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("disciplinability") != j.end() && !j.at("disciplinability").is_number_integer()) throw std::runtime_error("Expected integer");
         x.disciplinability = get_stack_optional<int64_t>(j, "disciplinability");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("goofer") != j.end() && !j.at("goofer").is_number_integer()) throw std::runtime_error("Expected integer");
         x.goofer = get_stack_optional<int64_t>(j, "goofer");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("laryngograph") != j.end() && !j.at("laryngograph").is_number_integer()) throw std::runtime_error("Expected integer");
         x.laryngograph = get_stack_optional<int64_t>(j, "laryngograph");
+        if (j.find("leucitis") != j.end() && !j.at("leucitis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.leucitis = get_stack_optional<int64_t>(j, "leucitis");
+        if (j.find("lymphocyst") != j.end() && !j.at("lymphocyst").is_number_integer()) throw std::runtime_error("Expected integer");
         x.lymphocyst = get_stack_optional<int64_t>(j, "lymphocyst");
+        if (j.find("microcosmology") != j.end() && !j.at("microcosmology").is_number_integer()) throw std::runtime_error("Expected integer");
         x.microcosmology = get_stack_optional<int64_t>(j, "microcosmology");
+        if (j.find("nauseation") != j.end() && !j.at("nauseation").is_number_integer()) throw std::runtime_error("Expected integer");
         x.nauseation = get_stack_optional<int64_t>(j, "nauseation");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("Patarin") != j.end() && !j.at("Patarin").is_number_integer()) throw std::runtime_error("Expected integer");
         x.patarin = get_stack_optional<int64_t>(j, "Patarin");
+        if (j.find("preliberal") != j.end() && !j.at("preliberal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.preliberal = get_stack_optional<int64_t>(j, "preliberal");
+        if (j.find("prettifier") != j.end() && !j.at("prettifier").is_number_integer()) throw std::runtime_error("Expected integer");
         x.prettifier = get_stack_optional<int64_t>(j, "prettifier");
+        if (j.find("rangework") != j.end() && !j.at("rangework").is_number_integer()) throw std::runtime_error("Expected integer");
         x.rangework = get_stack_optional<int64_t>(j, "rangework");
+        if (j.find("redient") != j.end() && !j.at("redient").is_number_integer()) throw std::runtime_error("Expected integer");
         x.redient = get_stack_optional<int64_t>(j, "redient");
+        if (j.find("subfusiform") != j.end() && !j.at("subfusiform").is_number_integer()) throw std::runtime_error("Expected integer");
         x.subfusiform = get_stack_optional<int64_t>(j, "subfusiform");
+        if (j.find("suicidical") != j.end() && !j.at("suicidical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.suicidical = get_stack_optional<int64_t>(j, "suicidical");
+        if (j.find("swow") != j.end() && !j.at("swow").is_number_integer()) throw std::runtime_error("Expected integer");
         x.swow = get_stack_optional<int64_t>(j, "swow");
+        if (j.find("wastrel") != j.end() && !j.at("wastrel").is_number_integer()) throw std::runtime_error("Expected integer");
         x.wastrel = get_stack_optional<int64_t>(j, "wastrel");
+        if (j.find("wingle") != j.end() && !j.at("wingle").is_number_integer()) throw std::runtime_error("Expected integer");
         x.wingle = get_stack_optional<int64_t>(j, "wingle");
     }
 
@@ -1044,30 +1087,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, LaviniaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("agitable") != j.end() && !j.at("agitable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.agitable = get_stack_optional<int64_t>(j, "agitable");
+        if (j.find("asininity") != j.end() && !j.at("asininity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.asininity = get_stack_optional<int64_t>(j, "asininity");
+        if (j.find("benefiter") != j.end() && !j.at("benefiter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.benefiter = get_stack_optional<int64_t>(j, "benefiter");
+        if (j.find("bronzelike") != j.end() && !j.at("bronzelike").is_number_integer()) throw std::runtime_error("Expected integer");
         x.bronzelike = get_stack_optional<int64_t>(j, "bronzelike");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("cholesteatomatous") != j.end() && !j.at("cholesteatomatous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.cholesteatomatous = get_stack_optional<int64_t>(j, "cholesteatomatous");
+        if (j.find("deprivement") != j.end() && !j.at("deprivement").is_number_integer()) throw std::runtime_error("Expected integer");
         x.deprivement = get_stack_optional<int64_t>(j, "deprivement");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("flippantness") != j.end() && !j.at("flippantness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.flippantness = get_stack_optional<int64_t>(j, "flippantness");
+        if (j.find("fogproof") != j.end() && !j.at("fogproof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.fogproof = get_stack_optional<int64_t>(j, "fogproof");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("merrymeeting") != j.end() && !j.at("merrymeeting").is_number_integer()) throw std::runtime_error("Expected integer");
         x.merrymeeting = get_stack_optional<int64_t>(j, "merrymeeting");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("overcareful") != j.end() && !j.at("overcareful").is_number_integer()) throw std::runtime_error("Expected integer");
         x.overcareful = get_stack_optional<int64_t>(j, "overcareful");
+        if (j.find("panaris") != j.end() && !j.at("panaris").is_number_integer()) throw std::runtime_error("Expected integer");
         x.panaris = get_stack_optional<int64_t>(j, "panaris");
+        if (j.find("preacceptance") != j.end() && !j.at("preacceptance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.preacceptance = get_stack_optional<int64_t>(j, "preacceptance");
+        if (j.find("quinoxaline") != j.end() && !j.at("quinoxaline").is_number_integer()) throw std::runtime_error("Expected integer");
         x.quinoxaline = get_stack_optional<int64_t>(j, "quinoxaline");
+        if (j.find("sig") != j.end() && !j.at("sig").is_number_integer()) throw std::runtime_error("Expected integer");
         x.sig = get_stack_optional<int64_t>(j, "sig");
+        if (j.find("superconfusion") != j.end() && !j.at("superconfusion").is_number_integer()) throw std::runtime_error("Expected integer");
         x.superconfusion = get_stack_optional<int64_t>(j, "superconfusion");
+        if (j.find("Tacana") != j.end() && !j.at("Tacana").is_number_integer()) throw std::runtime_error("Expected integer");
         x.tacana = get_stack_optional<int64_t>(j, "Tacana");
+        if (j.find("tillotter") != j.end() && !j.at("tillotter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.tillotter = get_stack_optional<int64_t>(j, "tillotter");
+        if (j.find("tranquillize") != j.end() && !j.at("tranquillize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.tranquillize = get_stack_optional<int64_t>(j, "tranquillize");
+        if (j.find("unquestionable") != j.end() && !j.at("unquestionable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.unquestionable = get_stack_optional<int64_t>(j, "unquestionable");
+        if (j.find("uproute") != j.end() && !j.at("uproute").is_number_integer()) throw std::runtime_error("Expected integer");
         x.uproute = get_stack_optional<int64_t>(j, "uproute");
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/combinations2.json/const-style-east-const--0048a2a7a881/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations2.json/const-style-east-const--0048a2a7a881/quicktype.hpp
index 6c24a89..0a8dfc5 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations2.json/const-style-east-const--0048a2a7a881/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations2.json/const-style-east-const--0048a2a7a881/quicktype.hpp
@@ -1769,6 +1769,7 @@ namespace quicktype {
     inline void from_json(json const & j, Rebecca& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -1786,30 +1787,51 @@ namespace quicktype {
 
     inline void from_json(json const & j, Amphithyron& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("akroasis") != j.end() && !j.at("akroasis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_akroasis(get_stack_optional<int64_t>(j, "akroasis"));
+        if (j.find("antiphonical") != j.end() && !j.at("antiphonical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_antiphonical(get_stack_optional<int64_t>(j, "antiphonical"));
+        if (j.find("basebred") != j.end() && !j.at("basebred").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_basebred(get_stack_optional<int64_t>(j, "basebred"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("conductometric") != j.end() && !j.at("conductometric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_conductometric(get_stack_optional<int64_t>(j, "conductometric"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("ensilation") != j.end() && !j.at("ensilation").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ensilation(get_stack_optional<int64_t>(j, "ensilation"));
+        if (j.find("eyebolt") != j.end() && !j.at("eyebolt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eyebolt(get_stack_optional<int64_t>(j, "eyebolt"));
+        if (j.find("fistulated") != j.end() && !j.at("fistulated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fistulated(get_stack_optional<int64_t>(j, "fistulated"));
+        if (j.find("heteropod") != j.end() && !j.at("heteropod").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_heteropod(get_stack_optional<int64_t>(j, "heteropod"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("Juniperus") != j.end() && !j.at("Juniperus").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_juniperus(get_stack_optional<int64_t>(j, "Juniperus"));
+        if (j.find("labyrinthically") != j.end() && !j.at("labyrinthically").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_labyrinthically(get_stack_optional<int64_t>(j, "labyrinthically"));
+        if (j.find("martyrization") != j.end() && !j.at("martyrization").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_martyrization(get_stack_optional<int64_t>(j, "martyrization"));
+        if (j.find("mispolicy") != j.end() && !j.at("mispolicy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mispolicy(get_stack_optional<int64_t>(j, "mispolicy"));
+        if (j.find("multipara") != j.end() && !j.at("multipara").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_multipara(get_stack_optional<int64_t>(j, "multipara"));
+        if (j.find("Nazirite") != j.end() && !j.at("Nazirite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nazirite(get_stack_optional<int64_t>(j, "Nazirite"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("possessorial") != j.end() && !j.at("possessorial").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_possessorial(get_stack_optional<int64_t>(j, "possessorial"));
+        if (j.find("shamed") != j.end() && !j.at("shamed").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_shamed(get_stack_optional<int64_t>(j, "shamed"));
+        if (j.find("shelfworn") != j.end() && !j.at("shelfworn").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_shelfworn(get_stack_optional<int64_t>(j, "shelfworn"));
+        if (j.find("stagnum") != j.end() && !j.at("stagnum").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stagnum(get_stack_optional<int64_t>(j, "stagnum"));
+        if (j.find("Those") != j.end() && !j.at("Those").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_those(get_stack_optional<int64_t>(j, "Those"));
+        if (j.find("undecimal") != j.end() && !j.at("undecimal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_undecimal(get_stack_optional<int64_t>(j, "undecimal"));
     }
 
@@ -1988,30 +2010,51 @@ namespace quicktype {
 
     inline void from_json(json const & j, DiscordiaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Altaic") != j.end() && !j.at("Altaic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_altaic(get_stack_optional<int64_t>(j, "Altaic"));
+        if (j.find("amoristic") != j.end() && !j.at("amoristic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_amoristic(get_stack_optional<int64_t>(j, "amoristic"));
+        if (j.find("blennophthalmia") != j.end() && !j.at("blennophthalmia").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_blennophthalmia(get_stack_optional<int64_t>(j, "blennophthalmia"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("disciplinability") != j.end() && !j.at("disciplinability").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_disciplinability(get_stack_optional<int64_t>(j, "disciplinability"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("goofer") != j.end() && !j.at("goofer").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_goofer(get_stack_optional<int64_t>(j, "goofer"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("laryngograph") != j.end() && !j.at("laryngograph").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_laryngograph(get_stack_optional<int64_t>(j, "laryngograph"));
+        if (j.find("leucitis") != j.end() && !j.at("leucitis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_leucitis(get_stack_optional<int64_t>(j, "leucitis"));
+        if (j.find("lymphocyst") != j.end() && !j.at("lymphocyst").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lymphocyst(get_stack_optional<int64_t>(j, "lymphocyst"));
+        if (j.find("microcosmology") != j.end() && !j.at("microcosmology").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_microcosmology(get_stack_optional<int64_t>(j, "microcosmology"));
+        if (j.find("nauseation") != j.end() && !j.at("nauseation").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nauseation(get_stack_optional<int64_t>(j, "nauseation"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("Patarin") != j.end() && !j.at("Patarin").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_patarin(get_stack_optional<int64_t>(j, "Patarin"));
+        if (j.find("preliberal") != j.end() && !j.at("preliberal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_preliberal(get_stack_optional<int64_t>(j, "preliberal"));
+        if (j.find("prettifier") != j.end() && !j.at("prettifier").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_prettifier(get_stack_optional<int64_t>(j, "prettifier"));
+        if (j.find("rangework") != j.end() && !j.at("rangework").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rangework(get_stack_optional<int64_t>(j, "rangework"));
+        if (j.find("redient") != j.end() && !j.at("redient").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_redient(get_stack_optional<int64_t>(j, "redient"));
+        if (j.find("subfusiform") != j.end() && !j.at("subfusiform").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_subfusiform(get_stack_optional<int64_t>(j, "subfusiform"));
+        if (j.find("suicidical") != j.end() && !j.at("suicidical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_suicidical(get_stack_optional<int64_t>(j, "suicidical"));
+        if (j.find("swow") != j.end() && !j.at("swow").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_swow(get_stack_optional<int64_t>(j, "swow"));
+        if (j.find("wastrel") != j.end() && !j.at("wastrel").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_wastrel(get_stack_optional<int64_t>(j, "wastrel"));
+        if (j.find("wingle") != j.end() && !j.at("wingle").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_wingle(get_stack_optional<int64_t>(j, "wingle"));
     }
 
@@ -2094,30 +2137,51 @@ namespace quicktype {
 
     inline void from_json(json const & j, LaviniaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("agitable") != j.end() && !j.at("agitable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_agitable(get_stack_optional<int64_t>(j, "agitable"));
+        if (j.find("asininity") != j.end() && !j.at("asininity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_asininity(get_stack_optional<int64_t>(j, "asininity"));
+        if (j.find("benefiter") != j.end() && !j.at("benefiter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_benefiter(get_stack_optional<int64_t>(j, "benefiter"));
+        if (j.find("bronzelike") != j.end() && !j.at("bronzelike").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bronzelike(get_stack_optional<int64_t>(j, "bronzelike"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("cholesteatomatous") != j.end() && !j.at("cholesteatomatous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cholesteatomatous(get_stack_optional<int64_t>(j, "cholesteatomatous"));
+        if (j.find("deprivement") != j.end() && !j.at("deprivement").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_deprivement(get_stack_optional<int64_t>(j, "deprivement"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("flippantness") != j.end() && !j.at("flippantness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_flippantness(get_stack_optional<int64_t>(j, "flippantness"));
+        if (j.find("fogproof") != j.end() && !j.at("fogproof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fogproof(get_stack_optional<int64_t>(j, "fogproof"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("merrymeeting") != j.end() && !j.at("merrymeeting").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_merrymeeting(get_stack_optional<int64_t>(j, "merrymeeting"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("overcareful") != j.end() && !j.at("overcareful").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_overcareful(get_stack_optional<int64_t>(j, "overcareful"));
+        if (j.find("panaris") != j.end() && !j.at("panaris").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_panaris(get_stack_optional<int64_t>(j, "panaris"));
+        if (j.find("preacceptance") != j.end() && !j.at("preacceptance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_preacceptance(get_stack_optional<int64_t>(j, "preacceptance"));
+        if (j.find("quinoxaline") != j.end() && !j.at("quinoxaline").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quinoxaline(get_stack_optional<int64_t>(j, "quinoxaline"));
+        if (j.find("sig") != j.end() && !j.at("sig").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sig(get_stack_optional<int64_t>(j, "sig"));
+        if (j.find("superconfusion") != j.end() && !j.at("superconfusion").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_superconfusion(get_stack_optional<int64_t>(j, "superconfusion"));
+        if (j.find("Tacana") != j.end() && !j.at("Tacana").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tacana(get_stack_optional<int64_t>(j, "Tacana"));
+        if (j.find("tillotter") != j.end() && !j.at("tillotter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tillotter(get_stack_optional<int64_t>(j, "tillotter"));
+        if (j.find("tranquillize") != j.end() && !j.at("tranquillize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tranquillize(get_stack_optional<int64_t>(j, "tranquillize"));
+        if (j.find("unquestionable") != j.end() && !j.at("unquestionable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unquestionable(get_stack_optional<int64_t>(j, "unquestionable"));
+        if (j.find("uproute") != j.end() && !j.at("uproute").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_uproute(get_stack_optional<int64_t>(j, "uproute"));
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/combinations2.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations2.json/default/quicktype.hpp
index d05f74b..07481ae 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations2.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations2.json/default/quicktype.hpp
@@ -1769,6 +1769,7 @@ namespace quicktype {
     inline void from_json(const json & j, Rebecca& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -1786,30 +1787,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, Amphithyron& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("akroasis") != j.end() && !j.at("akroasis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_akroasis(get_stack_optional<int64_t>(j, "akroasis"));
+        if (j.find("antiphonical") != j.end() && !j.at("antiphonical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_antiphonical(get_stack_optional<int64_t>(j, "antiphonical"));
+        if (j.find("basebred") != j.end() && !j.at("basebred").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_basebred(get_stack_optional<int64_t>(j, "basebred"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("conductometric") != j.end() && !j.at("conductometric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_conductometric(get_stack_optional<int64_t>(j, "conductometric"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("ensilation") != j.end() && !j.at("ensilation").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ensilation(get_stack_optional<int64_t>(j, "ensilation"));
+        if (j.find("eyebolt") != j.end() && !j.at("eyebolt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eyebolt(get_stack_optional<int64_t>(j, "eyebolt"));
+        if (j.find("fistulated") != j.end() && !j.at("fistulated").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fistulated(get_stack_optional<int64_t>(j, "fistulated"));
+        if (j.find("heteropod") != j.end() && !j.at("heteropod").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_heteropod(get_stack_optional<int64_t>(j, "heteropod"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("Juniperus") != j.end() && !j.at("Juniperus").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_juniperus(get_stack_optional<int64_t>(j, "Juniperus"));
+        if (j.find("labyrinthically") != j.end() && !j.at("labyrinthically").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_labyrinthically(get_stack_optional<int64_t>(j, "labyrinthically"));
+        if (j.find("martyrization") != j.end() && !j.at("martyrization").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_martyrization(get_stack_optional<int64_t>(j, "martyrization"));
+        if (j.find("mispolicy") != j.end() && !j.at("mispolicy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mispolicy(get_stack_optional<int64_t>(j, "mispolicy"));
+        if (j.find("multipara") != j.end() && !j.at("multipara").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_multipara(get_stack_optional<int64_t>(j, "multipara"));
+        if (j.find("Nazirite") != j.end() && !j.at("Nazirite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nazirite(get_stack_optional<int64_t>(j, "Nazirite"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("possessorial") != j.end() && !j.at("possessorial").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_possessorial(get_stack_optional<int64_t>(j, "possessorial"));
+        if (j.find("shamed") != j.end() && !j.at("shamed").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_shamed(get_stack_optional<int64_t>(j, "shamed"));
+        if (j.find("shelfworn") != j.end() && !j.at("shelfworn").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_shelfworn(get_stack_optional<int64_t>(j, "shelfworn"));
+        if (j.find("stagnum") != j.end() && !j.at("stagnum").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stagnum(get_stack_optional<int64_t>(j, "stagnum"));
+        if (j.find("Those") != j.end() && !j.at("Those").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_those(get_stack_optional<int64_t>(j, "Those"));
+        if (j.find("undecimal") != j.end() && !j.at("undecimal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_undecimal(get_stack_optional<int64_t>(j, "undecimal"));
     }
 
@@ -1988,30 +2010,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, DiscordiaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Altaic") != j.end() && !j.at("Altaic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_altaic(get_stack_optional<int64_t>(j, "Altaic"));
+        if (j.find("amoristic") != j.end() && !j.at("amoristic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_amoristic(get_stack_optional<int64_t>(j, "amoristic"));
+        if (j.find("blennophthalmia") != j.end() && !j.at("blennophthalmia").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_blennophthalmia(get_stack_optional<int64_t>(j, "blennophthalmia"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("disciplinability") != j.end() && !j.at("disciplinability").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_disciplinability(get_stack_optional<int64_t>(j, "disciplinability"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("goofer") != j.end() && !j.at("goofer").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_goofer(get_stack_optional<int64_t>(j, "goofer"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("laryngograph") != j.end() && !j.at("laryngograph").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_laryngograph(get_stack_optional<int64_t>(j, "laryngograph"));
+        if (j.find("leucitis") != j.end() && !j.at("leucitis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_leucitis(get_stack_optional<int64_t>(j, "leucitis"));
+        if (j.find("lymphocyst") != j.end() && !j.at("lymphocyst").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lymphocyst(get_stack_optional<int64_t>(j, "lymphocyst"));
+        if (j.find("microcosmology") != j.end() && !j.at("microcosmology").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_microcosmology(get_stack_optional<int64_t>(j, "microcosmology"));
+        if (j.find("nauseation") != j.end() && !j.at("nauseation").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nauseation(get_stack_optional<int64_t>(j, "nauseation"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("Patarin") != j.end() && !j.at("Patarin").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_patarin(get_stack_optional<int64_t>(j, "Patarin"));
+        if (j.find("preliberal") != j.end() && !j.at("preliberal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_preliberal(get_stack_optional<int64_t>(j, "preliberal"));
+        if (j.find("prettifier") != j.end() && !j.at("prettifier").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_prettifier(get_stack_optional<int64_t>(j, "prettifier"));
+        if (j.find("rangework") != j.end() && !j.at("rangework").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rangework(get_stack_optional<int64_t>(j, "rangework"));
+        if (j.find("redient") != j.end() && !j.at("redient").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_redient(get_stack_optional<int64_t>(j, "redient"));
+        if (j.find("subfusiform") != j.end() && !j.at("subfusiform").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_subfusiform(get_stack_optional<int64_t>(j, "subfusiform"));
+        if (j.find("suicidical") != j.end() && !j.at("suicidical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_suicidical(get_stack_optional<int64_t>(j, "suicidical"));
+        if (j.find("swow") != j.end() && !j.at("swow").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_swow(get_stack_optional<int64_t>(j, "swow"));
+        if (j.find("wastrel") != j.end() && !j.at("wastrel").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_wastrel(get_stack_optional<int64_t>(j, "wastrel"));
+        if (j.find("wingle") != j.end() && !j.at("wingle").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_wingle(get_stack_optional<int64_t>(j, "wingle"));
     }
 
@@ -2094,30 +2137,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, LaviniaClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("agitable") != j.end() && !j.at("agitable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_agitable(get_stack_optional<int64_t>(j, "agitable"));
+        if (j.find("asininity") != j.end() && !j.at("asininity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_asininity(get_stack_optional<int64_t>(j, "asininity"));
+        if (j.find("benefiter") != j.end() && !j.at("benefiter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_benefiter(get_stack_optional<int64_t>(j, "benefiter"));
+        if (j.find("bronzelike") != j.end() && !j.at("bronzelike").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bronzelike(get_stack_optional<int64_t>(j, "bronzelike"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("cholesteatomatous") != j.end() && !j.at("cholesteatomatous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cholesteatomatous(get_stack_optional<int64_t>(j, "cholesteatomatous"));
+        if (j.find("deprivement") != j.end() && !j.at("deprivement").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_deprivement(get_stack_optional<int64_t>(j, "deprivement"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("flippantness") != j.end() && !j.at("flippantness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_flippantness(get_stack_optional<int64_t>(j, "flippantness"));
+        if (j.find("fogproof") != j.end() && !j.at("fogproof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fogproof(get_stack_optional<int64_t>(j, "fogproof"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("merrymeeting") != j.end() && !j.at("merrymeeting").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_merrymeeting(get_stack_optional<int64_t>(j, "merrymeeting"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("overcareful") != j.end() && !j.at("overcareful").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_overcareful(get_stack_optional<int64_t>(j, "overcareful"));
+        if (j.find("panaris") != j.end() && !j.at("panaris").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_panaris(get_stack_optional<int64_t>(j, "panaris"));
+        if (j.find("preacceptance") != j.end() && !j.at("preacceptance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_preacceptance(get_stack_optional<int64_t>(j, "preacceptance"));
+        if (j.find("quinoxaline") != j.end() && !j.at("quinoxaline").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quinoxaline(get_stack_optional<int64_t>(j, "quinoxaline"));
+        if (j.find("sig") != j.end() && !j.at("sig").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sig(get_stack_optional<int64_t>(j, "sig"));
+        if (j.find("superconfusion") != j.end() && !j.at("superconfusion").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_superconfusion(get_stack_optional<int64_t>(j, "superconfusion"));
+        if (j.find("Tacana") != j.end() && !j.at("Tacana").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tacana(get_stack_optional<int64_t>(j, "Tacana"));
+        if (j.find("tillotter") != j.end() && !j.at("tillotter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tillotter(get_stack_optional<int64_t>(j, "tillotter"));
+        if (j.find("tranquillize") != j.end() && !j.at("tranquillize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tranquillize(get_stack_optional<int64_t>(j, "tranquillize"));
+        if (j.find("unquestionable") != j.end() && !j.at("unquestionable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unquestionable(get_stack_optional<int64_t>(j, "unquestionable"));
+        if (j.find("uproute") != j.end() && !j.at("uproute").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_uproute(get_stack_optional<int64_t>(j, "uproute"));
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/combinations3.json/code-format-with-struct--67c848c66185/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations3.json/code-format-with-struct--67c848c66185/quicktype.hpp
index 4dbc681..e846657 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations3.json/code-format-with-struct--67c848c66185/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations3.json/code-format-with-struct--67c848c66185/quicktype.hpp
@@ -925,29 +925,50 @@ namespace quicktype {
     inline void from_json(const json & j, LupusClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("Chlorioninae") != j.end() && !j.at("Chlorioninae").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chlorioninae = get_stack_optional<int64_t>(j, "Chlorioninae");
+        if (j.find("Corvinae") != j.end() && !j.at("Corvinae").is_number_integer()) throw std::runtime_error("Expected integer");
         x.corvinae = get_stack_optional<int64_t>(j, "Corvinae");
+        if (j.find("Crassina") != j.end() && !j.at("Crassina").is_number_integer()) throw std::runtime_error("Expected integer");
         x.crassina = get_stack_optional<int64_t>(j, "Crassina");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("exiguity") != j.end() && !j.at("exiguity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.exiguity = get_stack_optional<int64_t>(j, "exiguity");
+        if (j.find("farcist") != j.end() && !j.at("farcist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.farcist = get_stack_optional<int64_t>(j, "farcist");
+        if (j.find("holographical") != j.end() && !j.at("holographical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.holographical = get_stack_optional<int64_t>(j, "holographical");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("ichthyophagan") != j.end() && !j.at("ichthyophagan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.ichthyophagan = get_stack_optional<int64_t>(j, "ichthyophagan");
+        if (j.find("implacable") != j.end() && !j.at("implacable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.implacable = get_stack_optional<int64_t>(j, "implacable");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("outshiner") != j.end() && !j.at("outshiner").is_number_integer()) throw std::runtime_error("Expected integer");
         x.outshiner = get_stack_optional<int64_t>(j, "outshiner");
+        if (j.find("overweather") != j.end() && !j.at("overweather").is_number_integer()) throw std::runtime_error("Expected integer");
         x.overweather = get_stack_optional<int64_t>(j, "overweather");
+        if (j.find("protonegroid") != j.end() && !j.at("protonegroid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.protonegroid = get_stack_optional<int64_t>(j, "protonegroid");
+        if (j.find("shallowish") != j.end() && !j.at("shallowish").is_number_integer()) throw std::runtime_error("Expected integer");
         x.shallowish = get_stack_optional<int64_t>(j, "shallowish");
+        if (j.find("snoke") != j.end() && !j.at("snoke").is_number_integer()) throw std::runtime_error("Expected integer");
         x.snoke = get_stack_optional<int64_t>(j, "snoke");
+        if (j.find("snout") != j.end() && !j.at("snout").is_number_integer()) throw std::runtime_error("Expected integer");
         x.snout = get_stack_optional<int64_t>(j, "snout");
+        if (j.find("surveillance") != j.end() && !j.at("surveillance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.surveillance = get_stack_optional<int64_t>(j, "surveillance");
+        if (j.find("threshingtime") != j.end() && !j.at("threshingtime").is_number_integer()) throw std::runtime_error("Expected integer");
         x.threshingtime = get_stack_optional<int64_t>(j, "threshingtime");
+        if (j.find("Thysanocarpus") != j.end() && !j.at("Thysanocarpus").is_number_integer()) throw std::runtime_error("Expected integer");
         x.thysanocarpus = get_stack_optional<int64_t>(j, "Thysanocarpus");
+        if (j.find("unsignificantly") != j.end() && !j.at("unsignificantly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.unsignificantly = get_stack_optional<int64_t>(j, "unsignificantly");
+        if (j.find("unsnap") != j.end() && !j.at("unsnap").is_number_integer()) throw std::runtime_error("Expected integer");
         x.unsnap = get_stack_optional<int64_t>(j, "unsnap");
+        if (j.find("vendible") != j.end() && !j.at("vendible").is_number_integer()) throw std::runtime_error("Expected integer");
         x.vendible = get_stack_optional<int64_t>(j, "vendible");
     }
 
@@ -982,48 +1003,69 @@ namespace quicktype {
 
     inline void from_json(const json & j, Maslin& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Alicant") != j.end() && !j.at("Alicant").is_number_integer()) throw std::runtime_error("Expected integer");
         x.alicant = get_stack_optional<int64_t>(j, "Alicant");
         x.antiatonement = get_untyped(j, "antiatonement");
+        if (j.find("anticorrosive") != j.end() && !j.at("anticorrosive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.anticorrosive = get_stack_optional<int64_t>(j, "anticorrosive");
         x.aphidozer = get_untyped(j, "aphidozer");
         x.bakuninist = get_untyped(j, "Bakuninist");
+        if (j.find("be") != j.end() && !j.at("be").is_number_integer()) throw std::runtime_error("Expected integer");
         x.be = get_stack_optional<int64_t>(j, "be");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("chub") != j.end() && !j.at("chub").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chub = get_stack_optional<int64_t>(j, "chub");
+        if (j.find("cuprosilicon") != j.end() && !j.at("cuprosilicon").is_number_integer()) throw std::runtime_error("Expected integer");
         x.cuprosilicon = get_stack_optional<int64_t>(j, "cuprosilicon");
+        if (j.find("curtailedly") != j.end() && !j.at("curtailedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.curtailedly = get_stack_optional<int64_t>(j, "curtailedly");
+        if (j.find("dellenite") != j.end() && !j.at("dellenite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.dellenite = get_stack_optional<int64_t>(j, "dellenite");
+        if (j.find("Dimitry") != j.end() && !j.at("Dimitry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.dimitry = get_stack_optional<int64_t>(j, "Dimitry");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
         x.edifying = get_untyped(j, "edifying");
+        if (j.find("ethmoiditis") != j.end() && !j.at("ethmoiditis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.ethmoiditis = get_stack_optional<int64_t>(j, "ethmoiditis");
         x.gastralgy = get_untyped(j, "gastralgy");
+        if (j.find("goatherd") != j.end() && !j.at("goatherd").is_number_integer()) throw std::runtime_error("Expected integer");
         x.goatherd = get_stack_optional<int64_t>(j, "goatherd");
+        if (j.find("hammerdress") != j.end() && !j.at("hammerdress").is_number_integer()) throw std::runtime_error("Expected integer");
         x.hammerdress = get_stack_optional<int64_t>(j, "hammerdress");
         x.hangfire = get_untyped(j, "hangfire");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("lacunosity") != j.end() && !j.at("lacunosity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.lacunosity = get_stack_optional<int64_t>(j, "lacunosity");
         x.longiloquence = get_untyped(j, "longiloquence");
+        if (j.find("mameliere") != j.end() && !j.at("mameliere").is_number_integer()) throw std::runtime_error("Expected integer");
         x.mameliere = get_stack_optional<int64_t>(j, "mameliere");
         x.motherless = get_untyped(j, "motherless");
         x.nonbookish = get_untyped(j, "nonbookish");
         x.noncorrodible = get_untyped(j, "noncorrodible");
         x.nonsensicality = get_untyped(j, "nonsensicality");
+        if (j.find("oafishly") != j.end() && !j.at("oafishly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.oafishly = get_stack_optional<int64_t>(j, "oafishly");
         x.pfund = get_untyped(j, "pfund");
         x.preadvisory = get_untyped(j, "preadvisory");
         x.retroflexed = get_untyped(j, "retroflexed");
+        if (j.find("saccharulmic") != j.end() && !j.at("saccharulmic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.saccharulmic = get_stack_optional<int64_t>(j, "saccharulmic");
+        if (j.find("scowlful") != j.end() && !j.at("scowlful").is_number_integer()) throw std::runtime_error("Expected integer");
         x.scowlful = get_stack_optional<int64_t>(j, "scowlful");
         x.secluded = get_untyped(j, "secluded");
         x.slackage = get_untyped(j, "slackage");
+        if (j.find("sphaeridial") != j.end() && !j.at("sphaeridial").is_number_integer()) throw std::runtime_error("Expected integer");
         x.sphaeridial = get_stack_optional<int64_t>(j, "sphaeridial");
         x.spondulics = get_untyped(j, "spondulics");
+        if (j.find("subsecive") != j.end() && !j.at("subsecive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.subsecive = get_stack_optional<int64_t>(j, "subsecive");
         x.swellmobsman = get_untyped(j, "swellmobsman");
+        if (j.find("trachyglossate") != j.end() && !j.at("trachyglossate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.trachyglossate = get_stack_optional<int64_t>(j, "trachyglossate");
         x.trialogue = get_untyped(j, "trialogue");
+        if (j.find("unassuaged") != j.end() && !j.at("unassuaged").is_number_integer()) throw std::runtime_error("Expected integer");
         x.unassuaged = get_stack_optional<int64_t>(j, "unassuaged");
         x.ungross = get_untyped(j, "ungross");
         x.unjudiciously = get_untyped(j, "unjudiciously");
@@ -1081,6 +1123,7 @@ namespace quicktype {
     inline void from_json(const json & j, MonaziteClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.catharticalness = j.at("catharticalness").get<double>();
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = j.at("Chirotherium").get<int64_t>();
         x.disdiapason = j.at("disdiapason").get<std::string>();
         x.homocerc = j.at("homocerc").get<bool>();
@@ -1101,6 +1144,7 @@ namespace quicktype {
         x.blaspheme = get_untyped(j, "blaspheme");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
         x.celiosalpingectomy = get_untyped(j, "celiosalpingectomy");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.consummativeness = get_untyped(j, "consummativeness");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
@@ -1158,6 +1202,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.estevin = j.at("estevin").get<std::string>();
         x.jolterhead = j.at("jolterhead").get<double>();
+        if (j.find("sauternes") != j.end() && !j.at("sauternes").is_number_integer()) throw std::runtime_error("Expected integer");
         x.sauternes = j.at("sauternes").get<int64_t>();
         x.sparsely = j.at("sparsely").get<bool>();
         x.unrequested = get_untyped(j, "unrequested");
@@ -1270,30 +1315,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, PiaculumClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("alada") != j.end() && !j.at("alada").is_number_integer()) throw std::runtime_error("Expected integer");
         x.alada = get_stack_optional<int64_t>(j, "alada");
+        if (j.find("amphistomous") != j.end() && !j.at("amphistomous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.amphistomous = get_stack_optional<int64_t>(j, "amphistomous");
+        if (j.find("boysenberry") != j.end() && !j.at("boysenberry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.boysenberry = get_stack_optional<int64_t>(j, "boysenberry");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("decardinalize") != j.end() && !j.at("decardinalize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.decardinalize = get_stack_optional<int64_t>(j, "decardinalize");
+        if (j.find("discouragement") != j.end() && !j.at("discouragement").is_number_integer()) throw std::runtime_error("Expected integer");
         x.discouragement = get_stack_optional<int64_t>(j, "discouragement");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("doitrified") != j.end() && !j.at("doitrified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.doitrified = get_stack_optional<int64_t>(j, "doitrified");
+        if (j.find("hexaspermous") != j.end() && !j.at("hexaspermous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.hexaspermous = get_stack_optional<int64_t>(j, "hexaspermous");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("insinking") != j.end() && !j.at("insinking").is_number_integer()) throw std::runtime_error("Expected integer");
         x.insinking = get_stack_optional<int64_t>(j, "insinking");
+        if (j.find("loathfulness") != j.end() && !j.at("loathfulness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.loathfulness = get_stack_optional<int64_t>(j, "loathfulness");
+        if (j.find("miasmatical") != j.end() && !j.at("miasmatical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.miasmatical = get_stack_optional<int64_t>(j, "miasmatical");
+        if (j.find("neurofibril") != j.end() && !j.at("neurofibril").is_number_integer()) throw std::runtime_error("Expected integer");
         x.neurofibril = get_stack_optional<int64_t>(j, "neurofibril");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("phonendoscope") != j.end() && !j.at("phonendoscope").is_number_integer()) throw std::runtime_error("Expected integer");
         x.phonendoscope = get_stack_optional<int64_t>(j, "phonendoscope");
+        if (j.find("pilferment") != j.end() && !j.at("pilferment").is_number_integer()) throw std::runtime_error("Expected integer");
         x.pilferment = get_stack_optional<int64_t>(j, "pilferment");
+        if (j.find("predismissory") != j.end() && !j.at("predismissory").is_number_integer()) throw std::runtime_error("Expected integer");
         x.predismissory = get_stack_optional<int64_t>(j, "predismissory");
+        if (j.find("preinscription") != j.end() && !j.at("preinscription").is_number_integer()) throw std::runtime_error("Expected integer");
         x.preinscription = get_stack_optional<int64_t>(j, "preinscription");
+        if (j.find("quotative") != j.end() && !j.at("quotative").is_number_integer()) throw std::runtime_error("Expected integer");
         x.quotative = get_stack_optional<int64_t>(j, "quotative");
+        if (j.find("sienna") != j.end() && !j.at("sienna").is_number_integer()) throw std::runtime_error("Expected integer");
         x.sienna = get_stack_optional<int64_t>(j, "sienna");
+        if (j.find("thorax") != j.end() && !j.at("thorax").is_number_integer()) throw std::runtime_error("Expected integer");
         x.thorax = get_stack_optional<int64_t>(j, "thorax");
+        if (j.find("yachting") != j.end() && !j.at("yachting").is_number_integer()) throw std::runtime_error("Expected integer");
         x.yachting = get_stack_optional<int64_t>(j, "yachting");
+        if (j.find("Zipper") != j.end() && !j.at("Zipper").is_number_integer()) throw std::runtime_error("Expected integer");
         x.zipper = get_stack_optional<int64_t>(j, "Zipper");
     }
 
@@ -1330,6 +1396,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.carbonarism = get_untyped(j, "Carbonarism");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.cineolic = get_untyped(j, "cineolic");
         x.cobbly = get_untyped(j, "cobbly");
diff --git a/base/cplusplus/test/inputs/json/priority/combinations3.json/const-style-east-const--0048a2a7a881/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations3.json/const-style-east-const--0048a2a7a881/quicktype.hpp
index 6b89964..acb237f 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations3.json/const-style-east-const--0048a2a7a881/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations3.json/const-style-east-const--0048a2a7a881/quicktype.hpp
@@ -2367,29 +2367,50 @@ namespace quicktype {
     inline void from_json(json const & j, LupusClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("Chlorioninae") != j.end() && !j.at("Chlorioninae").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chlorioninae(get_stack_optional<int64_t>(j, "Chlorioninae"));
+        if (j.find("Corvinae") != j.end() && !j.at("Corvinae").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_corvinae(get_stack_optional<int64_t>(j, "Corvinae"));
+        if (j.find("Crassina") != j.end() && !j.at("Crassina").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_crassina(get_stack_optional<int64_t>(j, "Crassina"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("exiguity") != j.end() && !j.at("exiguity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_exiguity(get_stack_optional<int64_t>(j, "exiguity"));
+        if (j.find("farcist") != j.end() && !j.at("farcist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_farcist(get_stack_optional<int64_t>(j, "farcist"));
+        if (j.find("holographical") != j.end() && !j.at("holographical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_holographical(get_stack_optional<int64_t>(j, "holographical"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("ichthyophagan") != j.end() && !j.at("ichthyophagan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ichthyophagan(get_stack_optional<int64_t>(j, "ichthyophagan"));
+        if (j.find("implacable") != j.end() && !j.at("implacable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_implacable(get_stack_optional<int64_t>(j, "implacable"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("outshiner") != j.end() && !j.at("outshiner").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_outshiner(get_stack_optional<int64_t>(j, "outshiner"));
+        if (j.find("overweather") != j.end() && !j.at("overweather").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_overweather(get_stack_optional<int64_t>(j, "overweather"));
+        if (j.find("protonegroid") != j.end() && !j.at("protonegroid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_protonegroid(get_stack_optional<int64_t>(j, "protonegroid"));
+        if (j.find("shallowish") != j.end() && !j.at("shallowish").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_shallowish(get_stack_optional<int64_t>(j, "shallowish"));
+        if (j.find("snoke") != j.end() && !j.at("snoke").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_snoke(get_stack_optional<int64_t>(j, "snoke"));
+        if (j.find("snout") != j.end() && !j.at("snout").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_snout(get_stack_optional<int64_t>(j, "snout"));
+        if (j.find("surveillance") != j.end() && !j.at("surveillance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_surveillance(get_stack_optional<int64_t>(j, "surveillance"));
+        if (j.find("threshingtime") != j.end() && !j.at("threshingtime").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_threshingtime(get_stack_optional<int64_t>(j, "threshingtime"));
+        if (j.find("Thysanocarpus") != j.end() && !j.at("Thysanocarpus").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thysanocarpus(get_stack_optional<int64_t>(j, "Thysanocarpus"));
+        if (j.find("unsignificantly") != j.end() && !j.at("unsignificantly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsignificantly(get_stack_optional<int64_t>(j, "unsignificantly"));
+        if (j.find("unsnap") != j.end() && !j.at("unsnap").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsnap(get_stack_optional<int64_t>(j, "unsnap"));
+        if (j.find("vendible") != j.end() && !j.at("vendible").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_vendible(get_stack_optional<int64_t>(j, "vendible"));
     }
 
@@ -2424,48 +2445,69 @@ namespace quicktype {
 
     inline void from_json(json const & j, Maslin& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Alicant") != j.end() && !j.at("Alicant").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_alicant(get_stack_optional<int64_t>(j, "Alicant"));
         x.set_antiatonement(get_untyped(j, "antiatonement"));
+        if (j.find("anticorrosive") != j.end() && !j.at("anticorrosive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_anticorrosive(get_stack_optional<int64_t>(j, "anticorrosive"));
         x.set_aphidozer(get_untyped(j, "aphidozer"));
         x.set_bakuninist(get_untyped(j, "Bakuninist"));
+        if (j.find("be") != j.end() && !j.at("be").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_be(get_stack_optional<int64_t>(j, "be"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("chub") != j.end() && !j.at("chub").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chub(get_stack_optional<int64_t>(j, "chub"));
+        if (j.find("cuprosilicon") != j.end() && !j.at("cuprosilicon").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cuprosilicon(get_stack_optional<int64_t>(j, "cuprosilicon"));
+        if (j.find("curtailedly") != j.end() && !j.at("curtailedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_curtailedly(get_stack_optional<int64_t>(j, "curtailedly"));
+        if (j.find("dellenite") != j.end() && !j.at("dellenite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dellenite(get_stack_optional<int64_t>(j, "dellenite"));
+        if (j.find("Dimitry") != j.end() && !j.at("Dimitry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dimitry(get_stack_optional<int64_t>(j, "Dimitry"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_edifying(get_untyped(j, "edifying"));
+        if (j.find("ethmoiditis") != j.end() && !j.at("ethmoiditis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ethmoiditis(get_stack_optional<int64_t>(j, "ethmoiditis"));
         x.set_gastralgy(get_untyped(j, "gastralgy"));
+        if (j.find("goatherd") != j.end() && !j.at("goatherd").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_goatherd(get_stack_optional<int64_t>(j, "goatherd"));
+        if (j.find("hammerdress") != j.end() && !j.at("hammerdress").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hammerdress(get_stack_optional<int64_t>(j, "hammerdress"));
         x.set_hangfire(get_untyped(j, "hangfire"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("lacunosity") != j.end() && !j.at("lacunosity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lacunosity(get_stack_optional<int64_t>(j, "lacunosity"));
         x.set_longiloquence(get_untyped(j, "longiloquence"));
+        if (j.find("mameliere") != j.end() && !j.at("mameliere").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mameliere(get_stack_optional<int64_t>(j, "mameliere"));
         x.set_motherless(get_untyped(j, "motherless"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
         x.set_noncorrodible(get_untyped(j, "noncorrodible"));
         x.set_nonsensicality(get_untyped(j, "nonsensicality"));
+        if (j.find("oafishly") != j.end() && !j.at("oafishly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oafishly(get_stack_optional<int64_t>(j, "oafishly"));
         x.set_pfund(get_untyped(j, "pfund"));
         x.set_preadvisory(get_untyped(j, "preadvisory"));
         x.set_retroflexed(get_untyped(j, "retroflexed"));
+        if (j.find("saccharulmic") != j.end() && !j.at("saccharulmic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_saccharulmic(get_stack_optional<int64_t>(j, "saccharulmic"));
+        if (j.find("scowlful") != j.end() && !j.at("scowlful").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_scowlful(get_stack_optional<int64_t>(j, "scowlful"));
         x.set_secluded(get_untyped(j, "secluded"));
         x.set_slackage(get_untyped(j, "slackage"));
+        if (j.find("sphaeridial") != j.end() && !j.at("sphaeridial").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sphaeridial(get_stack_optional<int64_t>(j, "sphaeridial"));
         x.set_spondulics(get_untyped(j, "spondulics"));
+        if (j.find("subsecive") != j.end() && !j.at("subsecive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_subsecive(get_stack_optional<int64_t>(j, "subsecive"));
         x.set_swellmobsman(get_untyped(j, "swellmobsman"));
+        if (j.find("trachyglossate") != j.end() && !j.at("trachyglossate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_trachyglossate(get_stack_optional<int64_t>(j, "trachyglossate"));
         x.set_trialogue(get_untyped(j, "trialogue"));
+        if (j.find("unassuaged") != j.end() && !j.at("unassuaged").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unassuaged(get_stack_optional<int64_t>(j, "unassuaged"));
         x.set_ungross(get_untyped(j, "ungross"));
         x.set_unjudiciously(get_untyped(j, "unjudiciously"));
@@ -2523,6 +2565,7 @@ namespace quicktype {
     inline void from_json(json const & j, MonaziteClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -2543,6 +2586,7 @@ namespace quicktype {
         x.set_blaspheme(get_untyped(j, "blaspheme"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_celiosalpingectomy(get_untyped(j, "celiosalpingectomy"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_consummativeness(get_untyped(j, "consummativeness"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
@@ -2600,6 +2644,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_estevin(j.at("estevin").get<std::string>());
         x.set_jolterhead(j.at("jolterhead").get<double>());
+        if (j.find("sauternes") != j.end() && !j.at("sauternes").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sauternes(j.at("sauternes").get<int64_t>());
         x.set_sparsely(j.at("sparsely").get<bool>());
         x.set_unrequested(get_untyped(j, "unrequested"));
@@ -2712,30 +2757,51 @@ namespace quicktype {
 
     inline void from_json(json const & j, PiaculumClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("alada") != j.end() && !j.at("alada").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_alada(get_stack_optional<int64_t>(j, "alada"));
+        if (j.find("amphistomous") != j.end() && !j.at("amphistomous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_amphistomous(get_stack_optional<int64_t>(j, "amphistomous"));
+        if (j.find("boysenberry") != j.end() && !j.at("boysenberry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_boysenberry(get_stack_optional<int64_t>(j, "boysenberry"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("decardinalize") != j.end() && !j.at("decardinalize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_decardinalize(get_stack_optional<int64_t>(j, "decardinalize"));
+        if (j.find("discouragement") != j.end() && !j.at("discouragement").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_discouragement(get_stack_optional<int64_t>(j, "discouragement"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("doitrified") != j.end() && !j.at("doitrified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_doitrified(get_stack_optional<int64_t>(j, "doitrified"));
+        if (j.find("hexaspermous") != j.end() && !j.at("hexaspermous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hexaspermous(get_stack_optional<int64_t>(j, "hexaspermous"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("insinking") != j.end() && !j.at("insinking").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_insinking(get_stack_optional<int64_t>(j, "insinking"));
+        if (j.find("loathfulness") != j.end() && !j.at("loathfulness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_loathfulness(get_stack_optional<int64_t>(j, "loathfulness"));
+        if (j.find("miasmatical") != j.end() && !j.at("miasmatical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_miasmatical(get_stack_optional<int64_t>(j, "miasmatical"));
+        if (j.find("neurofibril") != j.end() && !j.at("neurofibril").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_neurofibril(get_stack_optional<int64_t>(j, "neurofibril"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("phonendoscope") != j.end() && !j.at("phonendoscope").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_phonendoscope(get_stack_optional<int64_t>(j, "phonendoscope"));
+        if (j.find("pilferment") != j.end() && !j.at("pilferment").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pilferment(get_stack_optional<int64_t>(j, "pilferment"));
+        if (j.find("predismissory") != j.end() && !j.at("predismissory").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_predismissory(get_stack_optional<int64_t>(j, "predismissory"));
+        if (j.find("preinscription") != j.end() && !j.at("preinscription").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_preinscription(get_stack_optional<int64_t>(j, "preinscription"));
+        if (j.find("quotative") != j.end() && !j.at("quotative").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quotative(get_stack_optional<int64_t>(j, "quotative"));
+        if (j.find("sienna") != j.end() && !j.at("sienna").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sienna(get_stack_optional<int64_t>(j, "sienna"));
+        if (j.find("thorax") != j.end() && !j.at("thorax").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thorax(get_stack_optional<int64_t>(j, "thorax"));
+        if (j.find("yachting") != j.end() && !j.at("yachting").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_yachting(get_stack_optional<int64_t>(j, "yachting"));
+        if (j.find("Zipper") != j.end() && !j.at("Zipper").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_zipper(get_stack_optional<int64_t>(j, "Zipper"));
     }
 
@@ -2772,6 +2838,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_carbonarism(get_untyped(j, "Carbonarism"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_cineolic(get_untyped(j, "cineolic"));
         x.set_cobbly(get_untyped(j, "cobbly"));
diff --git a/base/cplusplus/test/inputs/json/priority/combinations3.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations3.json/default/quicktype.hpp
index b6647b6..0294de9 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations3.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations3.json/default/quicktype.hpp
@@ -2367,29 +2367,50 @@ namespace quicktype {
     inline void from_json(const json & j, LupusClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("Chlorioninae") != j.end() && !j.at("Chlorioninae").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chlorioninae(get_stack_optional<int64_t>(j, "Chlorioninae"));
+        if (j.find("Corvinae") != j.end() && !j.at("Corvinae").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_corvinae(get_stack_optional<int64_t>(j, "Corvinae"));
+        if (j.find("Crassina") != j.end() && !j.at("Crassina").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_crassina(get_stack_optional<int64_t>(j, "Crassina"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("exiguity") != j.end() && !j.at("exiguity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_exiguity(get_stack_optional<int64_t>(j, "exiguity"));
+        if (j.find("farcist") != j.end() && !j.at("farcist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_farcist(get_stack_optional<int64_t>(j, "farcist"));
+        if (j.find("holographical") != j.end() && !j.at("holographical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_holographical(get_stack_optional<int64_t>(j, "holographical"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("ichthyophagan") != j.end() && !j.at("ichthyophagan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ichthyophagan(get_stack_optional<int64_t>(j, "ichthyophagan"));
+        if (j.find("implacable") != j.end() && !j.at("implacable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_implacable(get_stack_optional<int64_t>(j, "implacable"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("outshiner") != j.end() && !j.at("outshiner").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_outshiner(get_stack_optional<int64_t>(j, "outshiner"));
+        if (j.find("overweather") != j.end() && !j.at("overweather").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_overweather(get_stack_optional<int64_t>(j, "overweather"));
+        if (j.find("protonegroid") != j.end() && !j.at("protonegroid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_protonegroid(get_stack_optional<int64_t>(j, "protonegroid"));
+        if (j.find("shallowish") != j.end() && !j.at("shallowish").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_shallowish(get_stack_optional<int64_t>(j, "shallowish"));
+        if (j.find("snoke") != j.end() && !j.at("snoke").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_snoke(get_stack_optional<int64_t>(j, "snoke"));
+        if (j.find("snout") != j.end() && !j.at("snout").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_snout(get_stack_optional<int64_t>(j, "snout"));
+        if (j.find("surveillance") != j.end() && !j.at("surveillance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_surveillance(get_stack_optional<int64_t>(j, "surveillance"));
+        if (j.find("threshingtime") != j.end() && !j.at("threshingtime").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_threshingtime(get_stack_optional<int64_t>(j, "threshingtime"));
+        if (j.find("Thysanocarpus") != j.end() && !j.at("Thysanocarpus").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thysanocarpus(get_stack_optional<int64_t>(j, "Thysanocarpus"));
+        if (j.find("unsignificantly") != j.end() && !j.at("unsignificantly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsignificantly(get_stack_optional<int64_t>(j, "unsignificantly"));
+        if (j.find("unsnap") != j.end() && !j.at("unsnap").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsnap(get_stack_optional<int64_t>(j, "unsnap"));
+        if (j.find("vendible") != j.end() && !j.at("vendible").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_vendible(get_stack_optional<int64_t>(j, "vendible"));
     }
 
@@ -2424,48 +2445,69 @@ namespace quicktype {
 
     inline void from_json(const json & j, Maslin& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Alicant") != j.end() && !j.at("Alicant").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_alicant(get_stack_optional<int64_t>(j, "Alicant"));
         x.set_antiatonement(get_untyped(j, "antiatonement"));
+        if (j.find("anticorrosive") != j.end() && !j.at("anticorrosive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_anticorrosive(get_stack_optional<int64_t>(j, "anticorrosive"));
         x.set_aphidozer(get_untyped(j, "aphidozer"));
         x.set_bakuninist(get_untyped(j, "Bakuninist"));
+        if (j.find("be") != j.end() && !j.at("be").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_be(get_stack_optional<int64_t>(j, "be"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("chub") != j.end() && !j.at("chub").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chub(get_stack_optional<int64_t>(j, "chub"));
+        if (j.find("cuprosilicon") != j.end() && !j.at("cuprosilicon").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cuprosilicon(get_stack_optional<int64_t>(j, "cuprosilicon"));
+        if (j.find("curtailedly") != j.end() && !j.at("curtailedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_curtailedly(get_stack_optional<int64_t>(j, "curtailedly"));
+        if (j.find("dellenite") != j.end() && !j.at("dellenite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dellenite(get_stack_optional<int64_t>(j, "dellenite"));
+        if (j.find("Dimitry") != j.end() && !j.at("Dimitry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dimitry(get_stack_optional<int64_t>(j, "Dimitry"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_edifying(get_untyped(j, "edifying"));
+        if (j.find("ethmoiditis") != j.end() && !j.at("ethmoiditis").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ethmoiditis(get_stack_optional<int64_t>(j, "ethmoiditis"));
         x.set_gastralgy(get_untyped(j, "gastralgy"));
+        if (j.find("goatherd") != j.end() && !j.at("goatherd").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_goatherd(get_stack_optional<int64_t>(j, "goatherd"));
+        if (j.find("hammerdress") != j.end() && !j.at("hammerdress").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hammerdress(get_stack_optional<int64_t>(j, "hammerdress"));
         x.set_hangfire(get_untyped(j, "hangfire"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("lacunosity") != j.end() && !j.at("lacunosity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lacunosity(get_stack_optional<int64_t>(j, "lacunosity"));
         x.set_longiloquence(get_untyped(j, "longiloquence"));
+        if (j.find("mameliere") != j.end() && !j.at("mameliere").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mameliere(get_stack_optional<int64_t>(j, "mameliere"));
         x.set_motherless(get_untyped(j, "motherless"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
         x.set_noncorrodible(get_untyped(j, "noncorrodible"));
         x.set_nonsensicality(get_untyped(j, "nonsensicality"));
+        if (j.find("oafishly") != j.end() && !j.at("oafishly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oafishly(get_stack_optional<int64_t>(j, "oafishly"));
         x.set_pfund(get_untyped(j, "pfund"));
         x.set_preadvisory(get_untyped(j, "preadvisory"));
         x.set_retroflexed(get_untyped(j, "retroflexed"));
+        if (j.find("saccharulmic") != j.end() && !j.at("saccharulmic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_saccharulmic(get_stack_optional<int64_t>(j, "saccharulmic"));
+        if (j.find("scowlful") != j.end() && !j.at("scowlful").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_scowlful(get_stack_optional<int64_t>(j, "scowlful"));
         x.set_secluded(get_untyped(j, "secluded"));
         x.set_slackage(get_untyped(j, "slackage"));
+        if (j.find("sphaeridial") != j.end() && !j.at("sphaeridial").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sphaeridial(get_stack_optional<int64_t>(j, "sphaeridial"));
         x.set_spondulics(get_untyped(j, "spondulics"));
+        if (j.find("subsecive") != j.end() && !j.at("subsecive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_subsecive(get_stack_optional<int64_t>(j, "subsecive"));
         x.set_swellmobsman(get_untyped(j, "swellmobsman"));
+        if (j.find("trachyglossate") != j.end() && !j.at("trachyglossate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_trachyglossate(get_stack_optional<int64_t>(j, "trachyglossate"));
         x.set_trialogue(get_untyped(j, "trialogue"));
+        if (j.find("unassuaged") != j.end() && !j.at("unassuaged").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unassuaged(get_stack_optional<int64_t>(j, "unassuaged"));
         x.set_ungross(get_untyped(j, "ungross"));
         x.set_unjudiciously(get_untyped(j, "unjudiciously"));
@@ -2523,6 +2565,7 @@ namespace quicktype {
     inline void from_json(const json & j, MonaziteClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -2543,6 +2586,7 @@ namespace quicktype {
         x.set_blaspheme(get_untyped(j, "blaspheme"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_celiosalpingectomy(get_untyped(j, "celiosalpingectomy"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_consummativeness(get_untyped(j, "consummativeness"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
@@ -2600,6 +2644,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_estevin(j.at("estevin").get<std::string>());
         x.set_jolterhead(j.at("jolterhead").get<double>());
+        if (j.find("sauternes") != j.end() && !j.at("sauternes").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sauternes(j.at("sauternes").get<int64_t>());
         x.set_sparsely(j.at("sparsely").get<bool>());
         x.set_unrequested(get_untyped(j, "unrequested"));
@@ -2712,30 +2757,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, PiaculumClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("alada") != j.end() && !j.at("alada").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_alada(get_stack_optional<int64_t>(j, "alada"));
+        if (j.find("amphistomous") != j.end() && !j.at("amphistomous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_amphistomous(get_stack_optional<int64_t>(j, "amphistomous"));
+        if (j.find("boysenberry") != j.end() && !j.at("boysenberry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_boysenberry(get_stack_optional<int64_t>(j, "boysenberry"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("decardinalize") != j.end() && !j.at("decardinalize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_decardinalize(get_stack_optional<int64_t>(j, "decardinalize"));
+        if (j.find("discouragement") != j.end() && !j.at("discouragement").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_discouragement(get_stack_optional<int64_t>(j, "discouragement"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("doitrified") != j.end() && !j.at("doitrified").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_doitrified(get_stack_optional<int64_t>(j, "doitrified"));
+        if (j.find("hexaspermous") != j.end() && !j.at("hexaspermous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hexaspermous(get_stack_optional<int64_t>(j, "hexaspermous"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("insinking") != j.end() && !j.at("insinking").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_insinking(get_stack_optional<int64_t>(j, "insinking"));
+        if (j.find("loathfulness") != j.end() && !j.at("loathfulness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_loathfulness(get_stack_optional<int64_t>(j, "loathfulness"));
+        if (j.find("miasmatical") != j.end() && !j.at("miasmatical").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_miasmatical(get_stack_optional<int64_t>(j, "miasmatical"));
+        if (j.find("neurofibril") != j.end() && !j.at("neurofibril").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_neurofibril(get_stack_optional<int64_t>(j, "neurofibril"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("phonendoscope") != j.end() && !j.at("phonendoscope").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_phonendoscope(get_stack_optional<int64_t>(j, "phonendoscope"));
+        if (j.find("pilferment") != j.end() && !j.at("pilferment").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pilferment(get_stack_optional<int64_t>(j, "pilferment"));
+        if (j.find("predismissory") != j.end() && !j.at("predismissory").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_predismissory(get_stack_optional<int64_t>(j, "predismissory"));
+        if (j.find("preinscription") != j.end() && !j.at("preinscription").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_preinscription(get_stack_optional<int64_t>(j, "preinscription"));
+        if (j.find("quotative") != j.end() && !j.at("quotative").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quotative(get_stack_optional<int64_t>(j, "quotative"));
+        if (j.find("sienna") != j.end() && !j.at("sienna").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sienna(get_stack_optional<int64_t>(j, "sienna"));
+        if (j.find("thorax") != j.end() && !j.at("thorax").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thorax(get_stack_optional<int64_t>(j, "thorax"));
+        if (j.find("yachting") != j.end() && !j.at("yachting").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_yachting(get_stack_optional<int64_t>(j, "yachting"));
+        if (j.find("Zipper") != j.end() && !j.at("Zipper").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_zipper(get_stack_optional<int64_t>(j, "Zipper"));
     }
 
@@ -2772,6 +2838,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_carbonarism(get_untyped(j, "Carbonarism"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_cineolic(get_untyped(j, "cineolic"));
         x.set_cobbly(get_untyped(j, "cobbly"));
diff --git a/base/cplusplus/test/inputs/json/priority/combinations4.json/code-format-with-struct--67c848c66185/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations4.json/code-format-with-struct--67c848c66185/quicktype.hpp
index 2bd1031..e729efa 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations4.json/code-format-with-struct--67c848c66185/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations4.json/code-format-with-struct--67c848c66185/quicktype.hpp
@@ -1007,6 +1007,7 @@ namespace quicktype {
     inline void from_json(const json & j, QuebrachineClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.catharticalness = j.at("catharticalness").get<double>();
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = j.at("Chirotherium").get<int64_t>();
         x.disdiapason = j.at("disdiapason").get<std::string>();
         x.homocerc = j.at("homocerc").get<bool>();
@@ -1028,6 +1029,7 @@ namespace quicktype {
         x.anabolin = get_untyped(j, "anabolin");
         x.brainy = get_untyped(j, "brainy");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.chrysamine = get_untyped(j, "chrysamine");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
@@ -1230,6 +1232,7 @@ namespace quicktype {
         x.bowgrace = get_untyped(j, "bowgrace");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
         x.centaurid = get_untyped(j, "Centaurid");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
         x.flix = get_untyped(j, "flix");
@@ -1380,30 +1383,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, Staghunting& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("calorimetric") != j.end() && !j.at("calorimetric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.calorimetric = get_stack_optional<int64_t>(j, "calorimetric");
+        if (j.find("canid") != j.end() && !j.at("canid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.canid = get_stack_optional<int64_t>(j, "canid");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("ditriglyphic") != j.end() && !j.at("ditriglyphic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.ditriglyphic = get_stack_optional<int64_t>(j, "ditriglyphic");
+        if (j.find("floriferousness") != j.end() && !j.at("floriferousness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.floriferousness = get_stack_optional<int64_t>(j, "floriferousness");
+        if (j.find("gamelike") != j.end() && !j.at("gamelike").is_number_integer()) throw std::runtime_error("Expected integer");
         x.gamelike = get_stack_optional<int64_t>(j, "gamelike");
+        if (j.find("grig") != j.end() && !j.at("grig").is_number_integer()) throw std::runtime_error("Expected integer");
         x.grig = get_stack_optional<int64_t>(j, "grig");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("interloan") != j.end() && !j.at("interloan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.interloan = get_stack_optional<int64_t>(j, "interloan");
+        if (j.find("lithotomy") != j.end() && !j.at("lithotomy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.lithotomy = get_stack_optional<int64_t>(j, "lithotomy");
+        if (j.find("loric") != j.end() && !j.at("loric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.loric = get_stack_optional<int64_t>(j, "loric");
+        if (j.find("membranocoriaceous") != j.end() && !j.at("membranocoriaceous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.membranocoriaceous = get_stack_optional<int64_t>(j, "membranocoriaceous");
+        if (j.find("membranogenic") != j.end() && !j.at("membranogenic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.membranogenic = get_stack_optional<int64_t>(j, "membranogenic");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("overtrump") != j.end() && !j.at("overtrump").is_number_integer()) throw std::runtime_error("Expected integer");
         x.overtrump = get_stack_optional<int64_t>(j, "overtrump");
+        if (j.find("scotino") != j.end() && !j.at("scotino").is_number_integer()) throw std::runtime_error("Expected integer");
         x.scotino = get_stack_optional<int64_t>(j, "scotino");
+        if (j.find("seasonable") != j.end() && !j.at("seasonable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.seasonable = get_stack_optional<int64_t>(j, "seasonable");
+        if (j.find("sephen") != j.end() && !j.at("sephen").is_number_integer()) throw std::runtime_error("Expected integer");
         x.sephen = get_stack_optional<int64_t>(j, "sephen");
+        if (j.find("stigmarioid") != j.end() && !j.at("stigmarioid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.stigmarioid = get_stack_optional<int64_t>(j, "stigmarioid");
+        if (j.find("tired") != j.end() && !j.at("tired").is_number_integer()) throw std::runtime_error("Expected integer");
         x.tired = get_stack_optional<int64_t>(j, "tired");
+        if (j.find("trifid") != j.end() && !j.at("trifid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.trifid = get_stack_optional<int64_t>(j, "trifid");
+        if (j.find("undefeatedly") != j.end() && !j.at("undefeatedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.undefeatedly = get_stack_optional<int64_t>(j, "undefeatedly");
+        if (j.find("ungirlish") != j.end() && !j.at("ungirlish").is_number_integer()) throw std::runtime_error("Expected integer");
         x.ungirlish = get_stack_optional<int64_t>(j, "ungirlish");
     }
 
@@ -1438,30 +1462,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, StrenuosityClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bliss") != j.end() && !j.at("bliss").is_number_integer()) throw std::runtime_error("Expected integer");
         x.bliss = get_stack_optional<int64_t>(j, "bliss");
+        if (j.find("buccate") != j.end() && !j.at("buccate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.buccate = get_stack_optional<int64_t>(j, "buccate");
+        if (j.find("bulletproof") != j.end() && !j.at("bulletproof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.bulletproof = get_stack_optional<int64_t>(j, "bulletproof");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("crumblingness") != j.end() && !j.at("crumblingness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.crumblingness = get_stack_optional<int64_t>(j, "crumblingness");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("engagedly") != j.end() && !j.at("engagedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.engagedly = get_stack_optional<int64_t>(j, "engagedly");
+        if (j.find("fightable") != j.end() && !j.at("fightable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.fightable = get_stack_optional<int64_t>(j, "fightable");
+        if (j.find("hoariness") != j.end() && !j.at("hoariness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.hoariness = get_stack_optional<int64_t>(j, "hoariness");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("hypopodium") != j.end() && !j.at("hypopodium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.hypopodium = get_stack_optional<int64_t>(j, "hypopodium");
+        if (j.find("luxurist") != j.end() && !j.at("luxurist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.luxurist = get_stack_optional<int64_t>(j, "luxurist");
+        if (j.find("mechanician") != j.end() && !j.at("mechanician").is_number_integer()) throw std::runtime_error("Expected integer");
         x.mechanician = get_stack_optional<int64_t>(j, "mechanician");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("Onopordon") != j.end() && !j.at("Onopordon").is_number_integer()) throw std::runtime_error("Expected integer");
         x.onopordon = get_stack_optional<int64_t>(j, "Onopordon");
+        if (j.find("podgily") != j.end() && !j.at("podgily").is_number_integer()) throw std::runtime_error("Expected integer");
         x.podgily = get_stack_optional<int64_t>(j, "podgily");
+        if (j.find("reformableness") != j.end() && !j.at("reformableness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.reformableness = get_stack_optional<int64_t>(j, "reformableness");
+        if (j.find("scatterbrains") != j.end() && !j.at("scatterbrains").is_number_integer()) throw std::runtime_error("Expected integer");
         x.scatterbrains = get_stack_optional<int64_t>(j, "scatterbrains");
+        if (j.find("seminuria") != j.end() && !j.at("seminuria").is_number_integer()) throw std::runtime_error("Expected integer");
         x.seminuria = get_stack_optional<int64_t>(j, "seminuria");
+        if (j.find("Sodomite") != j.end() && !j.at("Sodomite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.sodomite = get_stack_optional<int64_t>(j, "Sodomite");
+        if (j.find("tramp") != j.end() && !j.at("tramp").is_number_integer()) throw std::runtime_error("Expected integer");
         x.tramp = get_stack_optional<int64_t>(j, "tramp");
+        if (j.find("undueness") != j.end() && !j.at("undueness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.undueness = get_stack_optional<int64_t>(j, "undueness");
+        if (j.find("worthily") != j.end() && !j.at("worthily").is_number_integer()) throw std::runtime_error("Expected integer");
         x.worthily = get_stack_optional<int64_t>(j, "worthily");
+        if (j.find("Yankeeist") != j.end() && !j.at("Yankeeist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.yankeeist = get_stack_optional<int64_t>(j, "Yankeeist");
     }
 
@@ -1501,6 +1546,7 @@ namespace quicktype {
         x.bungey = get_untyped(j, "bungey");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
         x.ceroxyle = get_untyped(j, "ceroxyle");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
         x.chorology = get_untyped(j, "chorology");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
@@ -1554,30 +1600,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, UnimpeachablyClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("acerin") != j.end() && !j.at("acerin").is_number_integer()) throw std::runtime_error("Expected integer");
         x.acerin = get_stack_optional<int64_t>(j, "acerin");
+        if (j.find("Bobadil") != j.end() && !j.at("Bobadil").is_number_integer()) throw std::runtime_error("Expected integer");
         x.bobadil = get_stack_optional<int64_t>(j, "Bobadil");
         x.catharticalness = get_stack_optional<double>(j, "catharticalness");
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chirotherium = get_stack_optional<int64_t>(j, "Chirotherium");
+        if (j.find("chlorophylligenous") != j.end() && !j.at("chlorophylligenous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.chlorophylligenous = get_stack_optional<int64_t>(j, "chlorophylligenous");
+        if (j.find("conversational") != j.end() && !j.at("conversational").is_number_integer()) throw std::runtime_error("Expected integer");
         x.conversational = get_stack_optional<int64_t>(j, "conversational");
+        if (j.find("demiowl") != j.end() && !j.at("demiowl").is_number_integer()) throw std::runtime_error("Expected integer");
         x.demiowl = get_stack_optional<int64_t>(j, "demiowl");
         x.disdiapason = get_stack_optional<std::string>(j, "disdiapason");
+        if (j.find("ectorhinal") != j.end() && !j.at("ectorhinal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.ectorhinal = get_stack_optional<int64_t>(j, "ectorhinal");
+        if (j.find("gamblesomeness") != j.end() && !j.at("gamblesomeness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.gamblesomeness = get_stack_optional<int64_t>(j, "gamblesomeness");
         x.homocerc = get_stack_optional<bool>(j, "homocerc");
+        if (j.find("irrorate") != j.end() && !j.at("irrorate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.irrorate = get_stack_optional<int64_t>(j, "irrorate");
+        if (j.find("kindergartening") != j.end() && !j.at("kindergartening").is_number_integer()) throw std::runtime_error("Expected integer");
         x.kindergartening = get_stack_optional<int64_t>(j, "kindergartening");
+        if (j.find("lateritic") != j.end() && !j.at("lateritic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.lateritic = get_stack_optional<int64_t>(j, "lateritic");
+        if (j.find("mespil") != j.end() && !j.at("mespil").is_number_integer()) throw std::runtime_error("Expected integer");
         x.mespil = get_stack_optional<int64_t>(j, "mespil");
+        if (j.find("misconfiguration") != j.end() && !j.at("misconfiguration").is_number_integer()) throw std::runtime_error("Expected integer");
         x.misconfiguration = get_stack_optional<int64_t>(j, "misconfiguration");
         x.nonbookish = get_untyped(j, "nonbookish");
+        if (j.find("planometry") != j.end() && !j.at("planometry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.planometry = get_stack_optional<int64_t>(j, "planometry");
+        if (j.find("Quiina") != j.end() && !j.at("Quiina").is_number_integer()) throw std::runtime_error("Expected integer");
         x.quiina = get_stack_optional<int64_t>(j, "Quiina");
+        if (j.find("Robert") != j.end() && !j.at("Robert").is_number_integer()) throw std::runtime_error("Expected integer");
         x.robert = get_stack_optional<int64_t>(j, "Robert");
+        if (j.find("rot") != j.end() && !j.at("rot").is_number_integer()) throw std::runtime_error("Expected integer");
         x.rot = get_stack_optional<int64_t>(j, "rot");
+        if (j.find("subcinctorium") != j.end() && !j.at("subcinctorium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.subcinctorium = get_stack_optional<int64_t>(j, "subcinctorium");
+        if (j.find("tussocker") != j.end() && !j.at("tussocker").is_number_integer()) throw std::runtime_error("Expected integer");
         x.tussocker = get_stack_optional<int64_t>(j, "tussocker");
+        if (j.find("ultraproud") != j.end() && !j.at("ultraproud").is_number_integer()) throw std::runtime_error("Expected integer");
         x.ultraproud = get_stack_optional<int64_t>(j, "ultraproud");
+        if (j.find("unsuggestedness") != j.end() && !j.at("unsuggestedness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.unsuggestedness = get_stack_optional<int64_t>(j, "unsuggestedness");
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/combinations4.json/const-style-east-const--0048a2a7a881/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations4.json/const-style-east-const--0048a2a7a881/quicktype.hpp
index bdfc776..a8a3608 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations4.json/const-style-east-const--0048a2a7a881/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations4.json/const-style-east-const--0048a2a7a881/quicktype.hpp
@@ -2661,6 +2661,7 @@ namespace quicktype {
     inline void from_json(json const & j, QuebrachineClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -2682,6 +2683,7 @@ namespace quicktype {
         x.set_anabolin(get_untyped(j, "anabolin"));
         x.set_brainy(get_untyped(j, "brainy"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_chrysamine(get_untyped(j, "chrysamine"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
@@ -2884,6 +2886,7 @@ namespace quicktype {
         x.set_bowgrace(get_untyped(j, "bowgrace"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_centaurid(get_untyped(j, "Centaurid"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_flix(get_untyped(j, "flix"));
@@ -3034,30 +3037,51 @@ namespace quicktype {
 
     inline void from_json(json const & j, Staghunting& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("calorimetric") != j.end() && !j.at("calorimetric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_calorimetric(get_stack_optional<int64_t>(j, "calorimetric"));
+        if (j.find("canid") != j.end() && !j.at("canid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_canid(get_stack_optional<int64_t>(j, "canid"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("ditriglyphic") != j.end() && !j.at("ditriglyphic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ditriglyphic(get_stack_optional<int64_t>(j, "ditriglyphic"));
+        if (j.find("floriferousness") != j.end() && !j.at("floriferousness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_floriferousness(get_stack_optional<int64_t>(j, "floriferousness"));
+        if (j.find("gamelike") != j.end() && !j.at("gamelike").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gamelike(get_stack_optional<int64_t>(j, "gamelike"));
+        if (j.find("grig") != j.end() && !j.at("grig").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_grig(get_stack_optional<int64_t>(j, "grig"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("interloan") != j.end() && !j.at("interloan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_interloan(get_stack_optional<int64_t>(j, "interloan"));
+        if (j.find("lithotomy") != j.end() && !j.at("lithotomy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lithotomy(get_stack_optional<int64_t>(j, "lithotomy"));
+        if (j.find("loric") != j.end() && !j.at("loric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_loric(get_stack_optional<int64_t>(j, "loric"));
+        if (j.find("membranocoriaceous") != j.end() && !j.at("membranocoriaceous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_membranocoriaceous(get_stack_optional<int64_t>(j, "membranocoriaceous"));
+        if (j.find("membranogenic") != j.end() && !j.at("membranogenic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_membranogenic(get_stack_optional<int64_t>(j, "membranogenic"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("overtrump") != j.end() && !j.at("overtrump").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_overtrump(get_stack_optional<int64_t>(j, "overtrump"));
+        if (j.find("scotino") != j.end() && !j.at("scotino").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_scotino(get_stack_optional<int64_t>(j, "scotino"));
+        if (j.find("seasonable") != j.end() && !j.at("seasonable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_seasonable(get_stack_optional<int64_t>(j, "seasonable"));
+        if (j.find("sephen") != j.end() && !j.at("sephen").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sephen(get_stack_optional<int64_t>(j, "sephen"));
+        if (j.find("stigmarioid") != j.end() && !j.at("stigmarioid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stigmarioid(get_stack_optional<int64_t>(j, "stigmarioid"));
+        if (j.find("tired") != j.end() && !j.at("tired").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tired(get_stack_optional<int64_t>(j, "tired"));
+        if (j.find("trifid") != j.end() && !j.at("trifid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_trifid(get_stack_optional<int64_t>(j, "trifid"));
+        if (j.find("undefeatedly") != j.end() && !j.at("undefeatedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_undefeatedly(get_stack_optional<int64_t>(j, "undefeatedly"));
+        if (j.find("ungirlish") != j.end() && !j.at("ungirlish").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ungirlish(get_stack_optional<int64_t>(j, "ungirlish"));
     }
 
@@ -3092,30 +3116,51 @@ namespace quicktype {
 
     inline void from_json(json const & j, StrenuosityClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bliss") != j.end() && !j.at("bliss").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bliss(get_stack_optional<int64_t>(j, "bliss"));
+        if (j.find("buccate") != j.end() && !j.at("buccate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_buccate(get_stack_optional<int64_t>(j, "buccate"));
+        if (j.find("bulletproof") != j.end() && !j.at("bulletproof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bulletproof(get_stack_optional<int64_t>(j, "bulletproof"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("crumblingness") != j.end() && !j.at("crumblingness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_crumblingness(get_stack_optional<int64_t>(j, "crumblingness"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("engagedly") != j.end() && !j.at("engagedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_engagedly(get_stack_optional<int64_t>(j, "engagedly"));
+        if (j.find("fightable") != j.end() && !j.at("fightable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fightable(get_stack_optional<int64_t>(j, "fightable"));
+        if (j.find("hoariness") != j.end() && !j.at("hoariness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hoariness(get_stack_optional<int64_t>(j, "hoariness"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("hypopodium") != j.end() && !j.at("hypopodium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hypopodium(get_stack_optional<int64_t>(j, "hypopodium"));
+        if (j.find("luxurist") != j.end() && !j.at("luxurist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_luxurist(get_stack_optional<int64_t>(j, "luxurist"));
+        if (j.find("mechanician") != j.end() && !j.at("mechanician").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mechanician(get_stack_optional<int64_t>(j, "mechanician"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("Onopordon") != j.end() && !j.at("Onopordon").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_onopordon(get_stack_optional<int64_t>(j, "Onopordon"));
+        if (j.find("podgily") != j.end() && !j.at("podgily").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_podgily(get_stack_optional<int64_t>(j, "podgily"));
+        if (j.find("reformableness") != j.end() && !j.at("reformableness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_reformableness(get_stack_optional<int64_t>(j, "reformableness"));
+        if (j.find("scatterbrains") != j.end() && !j.at("scatterbrains").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_scatterbrains(get_stack_optional<int64_t>(j, "scatterbrains"));
+        if (j.find("seminuria") != j.end() && !j.at("seminuria").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_seminuria(get_stack_optional<int64_t>(j, "seminuria"));
+        if (j.find("Sodomite") != j.end() && !j.at("Sodomite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sodomite(get_stack_optional<int64_t>(j, "Sodomite"));
+        if (j.find("tramp") != j.end() && !j.at("tramp").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tramp(get_stack_optional<int64_t>(j, "tramp"));
+        if (j.find("undueness") != j.end() && !j.at("undueness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_undueness(get_stack_optional<int64_t>(j, "undueness"));
+        if (j.find("worthily") != j.end() && !j.at("worthily").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_worthily(get_stack_optional<int64_t>(j, "worthily"));
+        if (j.find("Yankeeist") != j.end() && !j.at("Yankeeist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_yankeeist(get_stack_optional<int64_t>(j, "Yankeeist"));
     }
 
@@ -3155,6 +3200,7 @@ namespace quicktype {
         x.set_bungey(get_untyped(j, "bungey"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_ceroxyle(get_untyped(j, "ceroxyle"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_chorology(get_untyped(j, "chorology"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
@@ -3208,30 +3254,51 @@ namespace quicktype {
 
     inline void from_json(json const & j, UnimpeachablyClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("acerin") != j.end() && !j.at("acerin").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_acerin(get_stack_optional<int64_t>(j, "acerin"));
+        if (j.find("Bobadil") != j.end() && !j.at("Bobadil").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bobadil(get_stack_optional<int64_t>(j, "Bobadil"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("chlorophylligenous") != j.end() && !j.at("chlorophylligenous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chlorophylligenous(get_stack_optional<int64_t>(j, "chlorophylligenous"));
+        if (j.find("conversational") != j.end() && !j.at("conversational").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_conversational(get_stack_optional<int64_t>(j, "conversational"));
+        if (j.find("demiowl") != j.end() && !j.at("demiowl").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_demiowl(get_stack_optional<int64_t>(j, "demiowl"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("ectorhinal") != j.end() && !j.at("ectorhinal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ectorhinal(get_stack_optional<int64_t>(j, "ectorhinal"));
+        if (j.find("gamblesomeness") != j.end() && !j.at("gamblesomeness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gamblesomeness(get_stack_optional<int64_t>(j, "gamblesomeness"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("irrorate") != j.end() && !j.at("irrorate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_irrorate(get_stack_optional<int64_t>(j, "irrorate"));
+        if (j.find("kindergartening") != j.end() && !j.at("kindergartening").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kindergartening(get_stack_optional<int64_t>(j, "kindergartening"));
+        if (j.find("lateritic") != j.end() && !j.at("lateritic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lateritic(get_stack_optional<int64_t>(j, "lateritic"));
+        if (j.find("mespil") != j.end() && !j.at("mespil").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mespil(get_stack_optional<int64_t>(j, "mespil"));
+        if (j.find("misconfiguration") != j.end() && !j.at("misconfiguration").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_misconfiguration(get_stack_optional<int64_t>(j, "misconfiguration"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("planometry") != j.end() && !j.at("planometry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_planometry(get_stack_optional<int64_t>(j, "planometry"));
+        if (j.find("Quiina") != j.end() && !j.at("Quiina").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quiina(get_stack_optional<int64_t>(j, "Quiina"));
+        if (j.find("Robert") != j.end() && !j.at("Robert").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_robert(get_stack_optional<int64_t>(j, "Robert"));
+        if (j.find("rot") != j.end() && !j.at("rot").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rot(get_stack_optional<int64_t>(j, "rot"));
+        if (j.find("subcinctorium") != j.end() && !j.at("subcinctorium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_subcinctorium(get_stack_optional<int64_t>(j, "subcinctorium"));
+        if (j.find("tussocker") != j.end() && !j.at("tussocker").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tussocker(get_stack_optional<int64_t>(j, "tussocker"));
+        if (j.find("ultraproud") != j.end() && !j.at("ultraproud").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ultraproud(get_stack_optional<int64_t>(j, "ultraproud"));
+        if (j.find("unsuggestedness") != j.end() && !j.at("unsuggestedness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsuggestedness(get_stack_optional<int64_t>(j, "unsuggestedness"));
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/combinations4.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/combinations4.json/default/quicktype.hpp
index 31df459..dc48003 100644
--- a/base/cplusplus/test/inputs/json/priority/combinations4.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/combinations4.json/default/quicktype.hpp
@@ -2661,6 +2661,7 @@ namespace quicktype {
     inline void from_json(const json & j, QuebrachineClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_catharticalness(j.at("catharticalness").get<double>());
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(j.at("Chirotherium").get<int64_t>());
         x.set_disdiapason(j.at("disdiapason").get<std::string>());
         x.set_homocerc(j.at("homocerc").get<bool>());
@@ -2682,6 +2683,7 @@ namespace quicktype {
         x.set_anabolin(get_untyped(j, "anabolin"));
         x.set_brainy(get_untyped(j, "brainy"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_chrysamine(get_untyped(j, "chrysamine"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
@@ -2884,6 +2886,7 @@ namespace quicktype {
         x.set_bowgrace(get_untyped(j, "bowgrace"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_centaurid(get_untyped(j, "Centaurid"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
         x.set_flix(get_untyped(j, "flix"));
@@ -3034,30 +3037,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, Staghunting& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("calorimetric") != j.end() && !j.at("calorimetric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_calorimetric(get_stack_optional<int64_t>(j, "calorimetric"));
+        if (j.find("canid") != j.end() && !j.at("canid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_canid(get_stack_optional<int64_t>(j, "canid"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("ditriglyphic") != j.end() && !j.at("ditriglyphic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ditriglyphic(get_stack_optional<int64_t>(j, "ditriglyphic"));
+        if (j.find("floriferousness") != j.end() && !j.at("floriferousness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_floriferousness(get_stack_optional<int64_t>(j, "floriferousness"));
+        if (j.find("gamelike") != j.end() && !j.at("gamelike").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gamelike(get_stack_optional<int64_t>(j, "gamelike"));
+        if (j.find("grig") != j.end() && !j.at("grig").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_grig(get_stack_optional<int64_t>(j, "grig"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("interloan") != j.end() && !j.at("interloan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_interloan(get_stack_optional<int64_t>(j, "interloan"));
+        if (j.find("lithotomy") != j.end() && !j.at("lithotomy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lithotomy(get_stack_optional<int64_t>(j, "lithotomy"));
+        if (j.find("loric") != j.end() && !j.at("loric").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_loric(get_stack_optional<int64_t>(j, "loric"));
+        if (j.find("membranocoriaceous") != j.end() && !j.at("membranocoriaceous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_membranocoriaceous(get_stack_optional<int64_t>(j, "membranocoriaceous"));
+        if (j.find("membranogenic") != j.end() && !j.at("membranogenic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_membranogenic(get_stack_optional<int64_t>(j, "membranogenic"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("overtrump") != j.end() && !j.at("overtrump").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_overtrump(get_stack_optional<int64_t>(j, "overtrump"));
+        if (j.find("scotino") != j.end() && !j.at("scotino").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_scotino(get_stack_optional<int64_t>(j, "scotino"));
+        if (j.find("seasonable") != j.end() && !j.at("seasonable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_seasonable(get_stack_optional<int64_t>(j, "seasonable"));
+        if (j.find("sephen") != j.end() && !j.at("sephen").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sephen(get_stack_optional<int64_t>(j, "sephen"));
+        if (j.find("stigmarioid") != j.end() && !j.at("stigmarioid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stigmarioid(get_stack_optional<int64_t>(j, "stigmarioid"));
+        if (j.find("tired") != j.end() && !j.at("tired").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tired(get_stack_optional<int64_t>(j, "tired"));
+        if (j.find("trifid") != j.end() && !j.at("trifid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_trifid(get_stack_optional<int64_t>(j, "trifid"));
+        if (j.find("undefeatedly") != j.end() && !j.at("undefeatedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_undefeatedly(get_stack_optional<int64_t>(j, "undefeatedly"));
+        if (j.find("ungirlish") != j.end() && !j.at("ungirlish").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ungirlish(get_stack_optional<int64_t>(j, "ungirlish"));
     }
 
@@ -3092,30 +3116,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, StrenuosityClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bliss") != j.end() && !j.at("bliss").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bliss(get_stack_optional<int64_t>(j, "bliss"));
+        if (j.find("buccate") != j.end() && !j.at("buccate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_buccate(get_stack_optional<int64_t>(j, "buccate"));
+        if (j.find("bulletproof") != j.end() && !j.at("bulletproof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bulletproof(get_stack_optional<int64_t>(j, "bulletproof"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("crumblingness") != j.end() && !j.at("crumblingness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_crumblingness(get_stack_optional<int64_t>(j, "crumblingness"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("engagedly") != j.end() && !j.at("engagedly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_engagedly(get_stack_optional<int64_t>(j, "engagedly"));
+        if (j.find("fightable") != j.end() && !j.at("fightable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fightable(get_stack_optional<int64_t>(j, "fightable"));
+        if (j.find("hoariness") != j.end() && !j.at("hoariness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hoariness(get_stack_optional<int64_t>(j, "hoariness"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("hypopodium") != j.end() && !j.at("hypopodium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hypopodium(get_stack_optional<int64_t>(j, "hypopodium"));
+        if (j.find("luxurist") != j.end() && !j.at("luxurist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_luxurist(get_stack_optional<int64_t>(j, "luxurist"));
+        if (j.find("mechanician") != j.end() && !j.at("mechanician").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mechanician(get_stack_optional<int64_t>(j, "mechanician"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("Onopordon") != j.end() && !j.at("Onopordon").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_onopordon(get_stack_optional<int64_t>(j, "Onopordon"));
+        if (j.find("podgily") != j.end() && !j.at("podgily").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_podgily(get_stack_optional<int64_t>(j, "podgily"));
+        if (j.find("reformableness") != j.end() && !j.at("reformableness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_reformableness(get_stack_optional<int64_t>(j, "reformableness"));
+        if (j.find("scatterbrains") != j.end() && !j.at("scatterbrains").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_scatterbrains(get_stack_optional<int64_t>(j, "scatterbrains"));
+        if (j.find("seminuria") != j.end() && !j.at("seminuria").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_seminuria(get_stack_optional<int64_t>(j, "seminuria"));
+        if (j.find("Sodomite") != j.end() && !j.at("Sodomite").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sodomite(get_stack_optional<int64_t>(j, "Sodomite"));
+        if (j.find("tramp") != j.end() && !j.at("tramp").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tramp(get_stack_optional<int64_t>(j, "tramp"));
+        if (j.find("undueness") != j.end() && !j.at("undueness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_undueness(get_stack_optional<int64_t>(j, "undueness"));
+        if (j.find("worthily") != j.end() && !j.at("worthily").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_worthily(get_stack_optional<int64_t>(j, "worthily"));
+        if (j.find("Yankeeist") != j.end() && !j.at("Yankeeist").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_yankeeist(get_stack_optional<int64_t>(j, "Yankeeist"));
     }
 
@@ -3155,6 +3200,7 @@ namespace quicktype {
         x.set_bungey(get_untyped(j, "bungey"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
         x.set_ceroxyle(get_untyped(j, "ceroxyle"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
         x.set_chorology(get_untyped(j, "chorology"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
@@ -3208,30 +3254,51 @@ namespace quicktype {
 
     inline void from_json(const json & j, UnimpeachablyClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("acerin") != j.end() && !j.at("acerin").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_acerin(get_stack_optional<int64_t>(j, "acerin"));
+        if (j.find("Bobadil") != j.end() && !j.at("Bobadil").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bobadil(get_stack_optional<int64_t>(j, "Bobadil"));
         x.set_catharticalness(get_stack_optional<double>(j, "catharticalness"));
+        if (j.find("Chirotherium") != j.end() && !j.at("Chirotherium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chirotherium(get_stack_optional<int64_t>(j, "Chirotherium"));
+        if (j.find("chlorophylligenous") != j.end() && !j.at("chlorophylligenous").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chlorophylligenous(get_stack_optional<int64_t>(j, "chlorophylligenous"));
+        if (j.find("conversational") != j.end() && !j.at("conversational").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_conversational(get_stack_optional<int64_t>(j, "conversational"));
+        if (j.find("demiowl") != j.end() && !j.at("demiowl").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_demiowl(get_stack_optional<int64_t>(j, "demiowl"));
         x.set_disdiapason(get_stack_optional<std::string>(j, "disdiapason"));
+        if (j.find("ectorhinal") != j.end() && !j.at("ectorhinal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ectorhinal(get_stack_optional<int64_t>(j, "ectorhinal"));
+        if (j.find("gamblesomeness") != j.end() && !j.at("gamblesomeness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gamblesomeness(get_stack_optional<int64_t>(j, "gamblesomeness"));
         x.set_homocerc(get_stack_optional<bool>(j, "homocerc"));
+        if (j.find("irrorate") != j.end() && !j.at("irrorate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_irrorate(get_stack_optional<int64_t>(j, "irrorate"));
+        if (j.find("kindergartening") != j.end() && !j.at("kindergartening").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_kindergartening(get_stack_optional<int64_t>(j, "kindergartening"));
+        if (j.find("lateritic") != j.end() && !j.at("lateritic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lateritic(get_stack_optional<int64_t>(j, "lateritic"));
+        if (j.find("mespil") != j.end() && !j.at("mespil").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mespil(get_stack_optional<int64_t>(j, "mespil"));
+        if (j.find("misconfiguration") != j.end() && !j.at("misconfiguration").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_misconfiguration(get_stack_optional<int64_t>(j, "misconfiguration"));
         x.set_nonbookish(get_untyped(j, "nonbookish"));
+        if (j.find("planometry") != j.end() && !j.at("planometry").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_planometry(get_stack_optional<int64_t>(j, "planometry"));
+        if (j.find("Quiina") != j.end() && !j.at("Quiina").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quiina(get_stack_optional<int64_t>(j, "Quiina"));
+        if (j.find("Robert") != j.end() && !j.at("Robert").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_robert(get_stack_optional<int64_t>(j, "Robert"));
+        if (j.find("rot") != j.end() && !j.at("rot").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rot(get_stack_optional<int64_t>(j, "rot"));
+        if (j.find("subcinctorium") != j.end() && !j.at("subcinctorium").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_subcinctorium(get_stack_optional<int64_t>(j, "subcinctorium"));
+        if (j.find("tussocker") != j.end() && !j.at("tussocker").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tussocker(get_stack_optional<int64_t>(j, "tussocker"));
+        if (j.find("ultraproud") != j.end() && !j.at("ultraproud").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ultraproud(get_stack_optional<int64_t>(j, "ultraproud"));
+        if (j.find("unsuggestedness") != j.end() && !j.at("unsuggestedness").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsuggestedness(get_stack_optional<int64_t>(j, "unsuggestedness"));
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/direct-recursive.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/direct-recursive.json/default/quicktype.hpp
index aefb0f1..fecc0d1 100644
--- a/base/cplusplus/test/inputs/json/priority/direct-recursive.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/direct-recursive.json/default/quicktype.hpp
@@ -131,6 +131,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_also(get_heap_optional<TopLevel>(j, "also"));
         x.set_bar(j.at("bar").get<bool>());
+        if (j.find("foo") != j.end() && !j.at("foo").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("foo").get<int64_t>());
         x.set_moo(j.at("moo").get<double>());
         x.set_quux(j.at("quux").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/priority/identifiers.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/identifiers.json/default/quicktype.hpp
index 28b346c..40ad454 100644
--- a/base/cplusplus/test/inputs/json/priority/identifiers.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/identifiers.json/default/quicktype.hpp
@@ -190,6 +190,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelBla& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bar") != j.end() && !j.at("bar").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bar(j.at("bar").get<int64_t>());
     }
 
@@ -200,6 +201,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Empty& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("x") != j.end() && !j.at("x").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_x(j.at("x").get<int64_t>());
     }
 
@@ -222,7 +224,9 @@ namespace quicktype {
     inline void from_json(const json & j, Foo& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_bla(j.at("bla").get<FooBla>());
+        if (j.find("_") != j.end() && !j.at("_").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_empty(j.at("_").get<int64_t>());
+        if (j.find("__") != j.end() && !j.at("__").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("__").get<int64_t>());
     }
 
@@ -235,7 +239,9 @@ namespace quicktype {
 
     inline void from_json(const json & j, ThisIsAToughOne& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("\n\n\n") != j.end() && !j.at("\n\n\n").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_empty(j.at("\n\n\n").get<int64_t>());
+        if (j.find("\"") != j.end() && !j.at("\"").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_this_is_a_tough_one(j.at("\"").get<int64_t>());
     }
 
@@ -247,6 +253,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, EmptyClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("y") != j.end() && !j.at("y").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_y(j.at("y").get<int64_t>());
     }
 
@@ -261,6 +268,7 @@ namespace quicktype {
         x.set_empty(j.at("").get<Empty>());
         x.set_foo(j.at("foo").get<Foo>());
         x.set_this_is_a_tough_one(j.at("ThisIsA\U0001f61cTough\"\n\nOne").get<ThisIsAToughOne>());
+        if (j.find("!") != j.end() && !j.at("!").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_top_level(j.at("!").get<int64_t>());
         x.set_top_level_empty(j.at("Empty").get<EmptyClass>());
     }
diff --git a/base/cplusplus/test/inputs/json/priority/keywords.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/keywords.json/default/quicktype.hpp
index c059987..c3aa09a 100644
--- a/base/cplusplus/test/inputs/json/priority/keywords.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/keywords.json/default/quicktype.hpp
@@ -6300,6 +6300,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Abstract& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("abstract") != j.end() && !j.at("abstract").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_abstract(j.at("abstract").get<int64_t>());
     }
 
@@ -6310,6 +6311,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Any& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Any") != j.end() && !j.at("Any").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_any(j.at("Any").get<int64_t>());
     }
 
@@ -6320,6 +6322,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Array& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("array") != j.end() && !j.at("array").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_array(j.at("array").get<int64_t>());
     }
 
@@ -6330,6 +6333,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, As& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("as") != j.end() && !j.at("as").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_as(j.at("as").get<int64_t>());
     }
 
@@ -6340,6 +6344,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Assert& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("assert") != j.end() && !j.at("assert").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_assert(j.at("assert").get<int64_t>());
     }
 
@@ -6350,6 +6355,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Associatedtype& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("associatedtype") != j.end() && !j.at("associatedtype").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_associatedtype(j.at("associatedtype").get<int64_t>());
     }
 
@@ -6360,6 +6366,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Associativity& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("associativity") != j.end() && !j.at("associativity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_associativity(j.at("associativity").get<int64_t>());
     }
 
@@ -6370,6 +6377,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Async& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("async") != j.end() && !j.at("async").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_async(j.at("async").get<int64_t>());
     }
 
@@ -6380,6 +6388,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Atomic& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("atomic") != j.end() && !j.at("atomic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_atomic(j.at("atomic").get<int64_t>());
     }
 
@@ -6390,6 +6399,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Await& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("await") != j.end() && !j.at("await").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_await(j.at("await").get<int64_t>());
     }
 
@@ -6400,6 +6410,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Base& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("base") != j.end() && !j.at("base").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_base(j.at("base").get<int64_t>());
     }
 
@@ -6410,6 +6421,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Boolean& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("boolean") != j.end() && !j.at("boolean").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_boolean(j.at("boolean").get<int64_t>());
     }
 
@@ -6420,6 +6432,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Bycopy& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bycopy") != j.end() && !j.at("bycopy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bycopy(j.at("bycopy").get<int64_t>());
     }
 
@@ -6430,6 +6443,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Byref& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("byref") != j.end() && !j.at("byref").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_byref(j.at("byref").get<int64_t>());
     }
 
@@ -6440,6 +6454,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Byte& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("byte") != j.end() && !j.at("byte").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_byte(j.at("byte").get<int64_t>());
     }
 
@@ -6450,6 +6465,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Chan& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("chan") != j.end() && !j.at("chan").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_chan(j.at("chan").get<int64_t>());
     }
 
@@ -6460,6 +6476,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Checked& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("checked") != j.end() && !j.at("checked").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_checked(j.at("checked").get<int64_t>());
     }
 
@@ -6470,6 +6487,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Clone& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("clone") != j.end() && !j.at("clone").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_clone(j.at("clone").get<int64_t>());
     }
 
@@ -6480,6 +6498,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Complex& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("_Complex") != j.end() && !j.at("_Complex").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_complex(j.at("_Complex").get<int64_t>());
     }
 
@@ -6490,6 +6509,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Console& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("console") != j.end() && !j.at("console").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_console(j.at("console").get<int64_t>());
     }
 
@@ -6500,6 +6520,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Constructor& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("constructor") != j.end() && !j.at("constructor").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_constructor(j.at("constructor").get<int64_t>());
     }
 
@@ -6510,6 +6531,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Convenience& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("convenience") != j.end() && !j.at("convenience").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_convenience(j.at("convenience").get<int64_t>());
     }
 
@@ -6520,6 +6542,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Convert& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("convert") != j.end() && !j.at("convert").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_convert(j.at("convert").get<int64_t>());
     }
 
@@ -6530,6 +6553,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Converter& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("converter") != j.end() && !j.at("converter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_converter(j.at("converter").get<int64_t>());
     }
 
@@ -6540,6 +6564,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Date& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("date") != j.end() && !j.at("date").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_date(j.at("date").get<int64_t>());
     }
 
@@ -6550,6 +6575,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, DateParseHandling& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("date_parse_handling") != j.end() && !j.at("date_parse_handling").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_date_parse_handling(j.at("date_parse_handling").get<int64_t>());
     }
 
@@ -6560,6 +6586,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Debugger& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("debugger") != j.end() && !j.at("debugger").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_debugger(j.at("debugger").get<int64_t>());
     }
 
@@ -6570,6 +6597,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Decimal& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("decimal") != j.end() && !j.at("decimal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_decimal(j.at("decimal").get<int64_t>());
     }
 
@@ -6580,6 +6608,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Declare& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("declare") != j.end() && !j.at("declare").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_declare(j.at("declare").get<int64_t>());
     }
 
@@ -6590,6 +6619,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, DecodeString& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("decode_string") != j.end() && !j.at("decode_string").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_decode_string(j.at("decode_string").get<int64_t>());
     }
 
@@ -6600,6 +6630,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Empty& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("_") != j.end() && !j.at("_").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_empty(j.at("_").get<int64_t>());
     }
 
@@ -6610,6 +6641,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Obj1Bool& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bool") != j.end() && !j.at("bool").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bool_bool(j.at("bool").get<int64_t>());
     }
 
@@ -6620,6 +6652,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Imaginery& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("_Imaginery") != j.end() && !j.at("_Imaginery").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_imaginery(j.at("_Imaginery").get<int64_t>());
     }
 
@@ -6630,6 +6663,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Alignas& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("alignas") != j.end() && !j.at("alignas").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_alignas_alignas(j.at("alignas").get<int64_t>());
     }
 
@@ -6640,6 +6674,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Alignof& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("alignof") != j.end() && !j.at("alignof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_alignof_alignof(j.at("alignof").get<int64_t>());
     }
 
@@ -6650,6 +6685,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, And& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("and") != j.end() && !j.at("and").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_and_and(j.at("and").get<int64_t>());
     }
 
@@ -6660,6 +6696,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, AndEq& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("and_eq") != j.end() && !j.at("and_eq").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_and_eq_and_eq(j.at("and_eq").get<int64_t>());
     }
 
@@ -6670,6 +6707,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, AnyClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("any") != j.end() && !j.at("any").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_any(j.at("any").get<int64_t>());
     }
 
@@ -6680,6 +6718,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Asm& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("asm") != j.end() && !j.at("asm").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_asm_asm(j.at("asm").get<int64_t>());
     }
 
@@ -6690,6 +6729,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, AtomicCancel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("atomic_cancel") != j.end() && !j.at("atomic_cancel").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_atomic_cancel_atomic_cancel(j.at("atomic_cancel").get<int64_t>());
     }
 
@@ -6700,6 +6740,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, AtomicCommit& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("atomic_commit") != j.end() && !j.at("atomic_commit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_atomic_commit_atomic_commit(j.at("atomic_commit").get<int64_t>());
     }
 
@@ -6710,6 +6751,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, AtomicNoexcept& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("atomic_noexcept") != j.end() && !j.at("atomic_noexcept").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_atomic_noexcept_atomic_noexcept(j.at("atomic_noexcept").get<int64_t>());
     }
 
@@ -6720,6 +6762,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Auto& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("auto") != j.end() && !j.at("auto").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_auto_auto(j.at("auto").get<int64_t>());
     }
 
@@ -6730,6 +6773,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Bitand& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bitand") != j.end() && !j.at("bitand").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bitand_bitand(j.at("bitand").get<int64_t>());
     }
 
@@ -6740,6 +6784,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Bitor& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bitor") != j.end() && !j.at("bitor").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bitor_bitor(j.at("bitor").get<int64_t>());
     }
 
@@ -6750,6 +6795,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Bool& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("BOOL") != j.end() && !j.at("BOOL").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bool_bool(j.at("BOOL").get<int64_t>());
     }
 
@@ -6760,6 +6806,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Break& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("break") != j.end() && !j.at("break").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_break_break(j.at("break").get<int64_t>());
     }
 
@@ -6770,6 +6817,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Case& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("case") != j.end() && !j.at("case").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_case_case(j.at("case").get<int64_t>());
     }
 
@@ -6780,6 +6828,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Catch& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("catch") != j.end() && !j.at("catch").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_catch_catch(j.at("catch").get<int64_t>());
     }
 
@@ -6790,6 +6839,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Char& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("char") != j.end() && !j.at("char").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_char_char(j.at("char").get<int64_t>());
     }
 
@@ -6800,6 +6850,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Char16T& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("char16_t") != j.end() && !j.at("char16_t").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_char16_t_char16_t(j.at("char16_t").get<int64_t>());
     }
 
@@ -6810,6 +6861,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Char32T& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("char32_t") != j.end() && !j.at("char32_t").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_char32_t_char32_t(j.at("char32_t").get<int64_t>());
     }
 
@@ -6820,6 +6872,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Class& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Class") != j.end() && !j.at("Class").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_class_class(j.at("Class").get<int64_t>());
     }
 
@@ -6830,6 +6883,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, CoAwait& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("co_await") != j.end() && !j.at("co_await").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_co_await_co_await(j.at("co_await").get<int64_t>());
     }
 
@@ -6840,6 +6894,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, CoReturn& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("co_return") != j.end() && !j.at("co_return").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_co_return_co_return(j.at("co_return").get<int64_t>());
     }
 
@@ -6850,6 +6905,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, CoYield& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("co_yield") != j.end() && !j.at("co_yield").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_co_yield_co_yield(j.at("co_yield").get<int64_t>());
     }
 
@@ -6860,6 +6916,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Compl& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("compl") != j.end() && !j.at("compl").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_compl_compl(j.at("compl").get<int64_t>());
     }
 
@@ -6870,6 +6927,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Concept& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("concept") != j.end() && !j.at("concept").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_concept_concept(j.at("concept").get<int64_t>());
     }
 
@@ -6880,6 +6938,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Const& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("const") != j.end() && !j.at("const").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_const_const(j.at("const").get<int64_t>());
     }
 
@@ -6890,6 +6949,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, ConstCast& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("const_cast") != j.end() && !j.at("const_cast").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_const_cast_const_cast(j.at("const_cast").get<int64_t>());
     }
 
@@ -6900,6 +6960,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Constexpr& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("constexpr") != j.end() && !j.at("constexpr").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_constexpr_constexpr(j.at("constexpr").get<int64_t>());
     }
 
@@ -6910,6 +6971,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Continue& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("continue") != j.end() && !j.at("continue").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_continue_continue(j.at("continue").get<int64_t>());
     }
 
@@ -6920,6 +6982,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Decltype& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("decltype") != j.end() && !j.at("decltype").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_decltype_decltype(j.at("decltype").get<int64_t>());
     }
 
@@ -6930,6 +6993,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, BoolClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("_Bool") != j.end() && !j.at("_Bool").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bool_bool(j.at("_Bool").get<int64_t>());
     }
 
@@ -6940,6 +7004,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, ClassClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("class") != j.end() && !j.at("class").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_class_class(j.at("class").get<int64_t>());
     }
 
@@ -6980,6 +7045,7 @@ namespace quicktype {
         x.set_decimal(j.at("decimal").get<Decimal>());
         x.set_declare(j.at("declare").get<Declare>());
         x.set_decode_string(j.at("decode_string").get<DecodeString>());
+        if (j.find("dummy") != j.end() && !j.at("dummy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dummy(j.at("dummy").get<int64_t>());
         x.set_empty(j.at("_").get<Empty>());
         x.set_fluffy_bool(j.at("bool").get<Obj1Bool>());
@@ -7090,6 +7156,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Def& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("def") != j.end() && !j.at("def").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_def(j.at("def").get<int64_t>());
     }
 
@@ -7100,6 +7167,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Defer& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("defer") != j.end() && !j.at("defer").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_defer(j.at("defer").get<int64_t>());
     }
 
@@ -7110,6 +7178,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Deinit& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("deinit") != j.end() && !j.at("deinit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_deinit(j.at("deinit").get<int64_t>());
     }
 
@@ -7120,6 +7189,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Del& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("del") != j.end() && !j.at("del").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_del(j.at("del").get<int64_t>());
     }
 
@@ -7130,6 +7200,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Delegate& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("delegate") != j.end() && !j.at("delegate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_delegate(j.at("delegate").get<int64_t>());
     }
 
@@ -7140,6 +7211,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Dict& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dict") != j.end() && !j.at("dict").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dict(j.at("dict").get<int64_t>());
     }
 
@@ -7150,6 +7222,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Dictionary& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dictionary") != j.end() && !j.at("dictionary").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dictionary(j.at("dictionary").get<int64_t>());
     }
 
@@ -7160,6 +7233,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, DidSet& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("didSet") != j.end() && !j.at("didSet").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_did_set(j.at("didSet").get<int64_t>());
     }
 
@@ -7170,6 +7244,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Dynamic& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dynamic") != j.end() && !j.at("dynamic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dynamic(j.at("dynamic").get<int64_t>());
     }
 
@@ -7180,6 +7255,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Elif& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("elif") != j.end() && !j.at("elif").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_elif(j.at("elif").get<int64_t>());
     }
 
@@ -7190,6 +7266,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, EncodeQuickType& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("encode_quick_type") != j.end() && !j.at("encode_quick_type").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_encode_quick_type(j.at("encode_quick_type").get<int64_t>());
     }
 
@@ -7200,6 +7277,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, EqualityContract& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("equalityContract") != j.end() && !j.at("equalityContract").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_equality_contract(j.at("equalityContract").get<int64_t>());
     }
 
@@ -7210,6 +7288,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Event& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("event") != j.end() && !j.at("event").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_event(j.at("event").get<int64_t>());
     }
 
@@ -7220,6 +7299,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Except& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("except") != j.end() && !j.at("except").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_except(j.at("except").get<int64_t>());
     }
 
@@ -7230,6 +7310,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Exception& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("exception") != j.end() && !j.at("exception").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_exception(j.at("exception").get<int64_t>());
     }
 
@@ -7240,6 +7321,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Exposing& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("exposing") != j.end() && !j.at("exposing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_exposing(j.at("exposing").get<int64_t>());
     }
 
@@ -7250,6 +7332,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Extends& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("extends") != j.end() && !j.at("extends").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_extends(j.at("extends").get<int64_t>());
     }
 
@@ -7260,6 +7343,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Extension& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("extension") != j.end() && !j.at("extension").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_extension(j.at("extension").get<int64_t>());
     }
 
@@ -7270,6 +7354,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Fallthrough& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("fallthrough") != j.end() && !j.at("fallthrough").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fallthrough(j.at("fallthrough").get<int64_t>());
     }
 
@@ -7280,6 +7365,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Fileprivate& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("fileprivate") != j.end() && !j.at("fileprivate").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fileprivate(j.at("fileprivate").get<int64_t>());
     }
 
@@ -7290,6 +7376,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Finally& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("finally") != j.end() && !j.at("finally").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_finally(j.at("finally").get<int64_t>());
     }
 
@@ -7300,6 +7387,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Fixed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("fixed") != j.end() && !j.at("fixed").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fixed(j.at("fixed").get<int64_t>());
     }
 
@@ -7310,6 +7398,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Foreach& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("foreach") != j.end() && !j.at("foreach").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foreach(j.at("foreach").get<int64_t>());
     }
 
@@ -7320,6 +7409,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, From& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("from") != j.end() && !j.at("from").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_from(j.at("from").get<int64_t>());
     }
 
@@ -7330,6 +7420,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, FromJson& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("from_json") != j.end() && !j.at("from_json").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_from_json(j.at("from_json").get<int64_t>());
     }
 
@@ -7340,6 +7431,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Func& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("func") != j.end() && !j.at("func").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_func(j.at("func").get<int64_t>());
     }
 
@@ -7350,6 +7442,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Function& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("function") != j.end() && !j.at("function").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_function(j.at("function").get<int64_t>());
     }
 
@@ -7360,6 +7453,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Get& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("get") != j.end() && !j.at("get").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_get(j.at("get").get<int64_t>());
     }
 
@@ -7370,6 +7464,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Global& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("global") != j.end() && !j.at("global").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_global(j.at("global").get<int64_t>());
     }
 
@@ -7380,6 +7475,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Go& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("go") != j.end() && !j.at("go").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_go(j.at("go").get<int64_t>());
     }
 
@@ -7390,6 +7486,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Guard& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("guard") != j.end() && !j.at("guard").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_guard(j.at("guard").get<int64_t>());
     }
 
@@ -7400,6 +7497,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, HasOwnProperty& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("hasOwnProperty") != j.end() && !j.at("hasOwnProperty").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_has_own_property(j.at("hasOwnProperty").get<int64_t>());
     }
 
@@ -7410,6 +7508,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Id& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
     }
 
@@ -7420,6 +7519,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Imp& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("IMP") != j.end() && !j.at("IMP").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_imp(j.at("IMP").get<int64_t>());
     }
 
@@ -7430,6 +7530,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Implements& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("implements") != j.end() && !j.at("implements").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_implements(j.at("implements").get<int64_t>());
     }
 
@@ -7440,6 +7541,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Implicit& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("implicit") != j.end() && !j.at("implicit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_implicit(j.at("implicit").get<int64_t>());
     }
 
@@ -7450,6 +7552,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, In& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("in") != j.end() && !j.at("in").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_in(j.at("in").get<int64_t>());
     }
 
@@ -7460,6 +7563,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Indirect& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("indirect") != j.end() && !j.at("indirect").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_indirect(j.at("indirect").get<int64_t>());
     }
 
@@ -7470,6 +7574,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Infix& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("infix") != j.end() && !j.at("infix").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_infix(j.at("infix").get<int64_t>());
     }
 
@@ -7480,6 +7585,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Init& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("init") != j.end() && !j.at("init").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_init(j.at("init").get<int64_t>());
     }
 
@@ -7490,6 +7596,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Inout& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("inout") != j.end() && !j.at("inout").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_inout(j.at("inout").get<int64_t>());
     }
 
@@ -7500,6 +7607,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Instanceof& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("instanceof") != j.end() && !j.at("instanceof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_instanceof(j.at("instanceof").get<int64_t>());
     }
 
@@ -7510,6 +7618,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Interface& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("interface") != j.end() && !j.at("interface").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_interface(j.at("interface").get<int64_t>());
     }
 
@@ -7520,6 +7629,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Internal& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("internal") != j.end() && !j.at("internal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_internal(j.at("internal").get<int64_t>());
     }
 
@@ -7530,6 +7640,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Default& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("default") != j.end() && !j.at("default").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_default_default(j.at("default").get<int64_t>());
     }
 
@@ -7540,6 +7651,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Delete& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("delete") != j.end() && !j.at("delete").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_delete_delete(j.at("delete").get<int64_t>());
     }
 
@@ -7550,6 +7662,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Do& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("do") != j.end() && !j.at("do").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_do_do(j.at("do").get<int64_t>());
     }
 
@@ -7560,6 +7673,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Double& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("double") != j.end() && !j.at("double").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_double_double(j.at("double").get<int64_t>());
     }
 
@@ -7570,6 +7684,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, DynamicCast& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dynamic_cast") != j.end() && !j.at("dynamic_cast").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dynamic_cast_dynamic_cast(j.at("dynamic_cast").get<int64_t>());
     }
 
@@ -7580,6 +7695,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Else& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("else") != j.end() && !j.at("else").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_else_else(j.at("else").get<int64_t>());
     }
 
@@ -7590,6 +7706,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Enum& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("enum") != j.end() && !j.at("enum").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_enum_enum(j.at("enum").get<int64_t>());
     }
 
@@ -7600,6 +7717,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Explicit& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("explicit") != j.end() && !j.at("explicit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_explicit_explicit(j.at("explicit").get<int64_t>());
     }
 
@@ -7610,6 +7728,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Export& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("export") != j.end() && !j.at("export").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_export_export(j.at("export").get<int64_t>());
     }
 
@@ -7620,6 +7739,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Extern& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("extern") != j.end() && !j.at("extern").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_extern_extern(j.at("extern").get<int64_t>());
     }
 
@@ -7630,6 +7750,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, False& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("False") != j.end() && !j.at("False").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_false_false(j.at("False").get<int64_t>());
     }
 
@@ -7640,6 +7761,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Final& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("final") != j.end() && !j.at("final").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_final_final(j.at("final").get<int64_t>());
     }
 
@@ -7650,6 +7772,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Float& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("float") != j.end() && !j.at("float").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_float_float(j.at("float").get<int64_t>());
     }
 
@@ -7660,6 +7783,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, For& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("for") != j.end() && !j.at("for").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_for_for(j.at("for").get<int64_t>());
     }
 
@@ -7670,6 +7794,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Friend& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("friend") != j.end() && !j.at("friend").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_friend_friend(j.at("friend").get<int64_t>());
     }
 
@@ -7680,6 +7805,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Goto& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("goto") != j.end() && !j.at("goto").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_goto_goto(j.at("goto").get<int64_t>());
     }
 
@@ -7690,6 +7816,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, If& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("if") != j.end() && !j.at("if").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_if_if(j.at("if").get<int64_t>());
     }
 
@@ -7700,6 +7827,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Import& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("import") != j.end() && !j.at("import").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_import_import(j.at("import").get<int64_t>());
     }
 
@@ -7710,6 +7838,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Inline& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("inline") != j.end() && !j.at("inline").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_inline_inline(j.at("inline").get<int64_t>());
     }
 
@@ -7720,6 +7849,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Int& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("int") != j.end() && !j.at("int").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_int_int(j.at("int").get<int64_t>());
     }
 
@@ -7730,6 +7860,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, FalseClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("false") != j.end() && !j.at("false").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_false_false(j.at("false").get<int64_t>());
     }
 
@@ -7748,6 +7879,7 @@ namespace quicktype {
         x.set_dict(j.at("dict").get<Dict>());
         x.set_dictionary(j.at("dictionary").get<Dictionary>());
         x.set_did_set(j.at("didSet").get<DidSet>());
+        if (j.find("dummy") != j.end() && !j.at("dummy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dummy(j.at("dummy").get<int64_t>());
         x.set_dynamic(j.at("dynamic").get<Dynamic>());
         x.set_elif(j.at("elif").get<Elif>());
@@ -7880,6 +8012,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Is& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("is") != j.end() && !j.at("is").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_is(j.at("is").get<int64_t>());
     }
 
@@ -7890,6 +8023,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Iterable& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("iterable") != j.end() && !j.at("iterable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_iterable(j.at("iterable").get<int64_t>());
     }
 
@@ -7900,6 +8034,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Jdec& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("jdec") != j.end() && !j.at("jdec").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_jdec(j.at("jdec").get<int64_t>());
     }
 
@@ -7910,6 +8045,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Jenc& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("jenc") != j.end() && !j.at("jenc").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_jenc(j.at("jenc").get<int64_t>());
     }
 
@@ -7920,6 +8056,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Jpipe& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("jpipe") != j.end() && !j.at("jpipe").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_jpipe(j.at("jpipe").get<int64_t>());
     }
 
@@ -7930,6 +8067,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Json& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("json") != j.end() && !j.at("json").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_json(j.at("json").get<int64_t>());
     }
 
@@ -7940,6 +8078,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, JsonConverter& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("json_converter") != j.end() && !j.at("json_converter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_json_converter(j.at("json_converter").get<int64_t>());
     }
 
@@ -7950,6 +8089,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, JsonSerializer& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("json_serializer") != j.end() && !j.at("json_serializer").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_json_serializer(j.at("json_serializer").get<int64_t>());
     }
 
@@ -7960,6 +8100,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, JsonToken& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("json_token") != j.end() && !j.at("json_token").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_json_token(j.at("json_token").get<int64_t>());
     }
 
@@ -7970,6 +8111,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, JsonWriter& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("json_writer") != j.end() && !j.at("json_writer").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_json_writer(j.at("json_writer").get<int64_t>());
     }
 
@@ -7980,6 +8122,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Lambda& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("lambda") != j.end() && !j.at("lambda").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lambda(j.at("lambda").get<int64_t>());
     }
 
@@ -7990,6 +8133,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Lazy& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("lazy") != j.end() && !j.at("lazy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lazy(j.at("lazy").get<int64_t>());
     }
 
@@ -8000,6 +8144,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Left& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("left") != j.end() && !j.at("left").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_left(j.at("left").get<int64_t>());
     }
 
@@ -8010,6 +8155,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Let& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("let") != j.end() && !j.at("let").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_let(j.at("let").get<int64_t>());
     }
 
@@ -8020,6 +8166,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, List& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("list") != j.end() && !j.at("list").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_list(j.at("list").get<int64_t>());
     }
 
@@ -8030,6 +8177,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Lock& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("lock") != j.end() && !j.at("lock").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lock(j.at("lock").get<int64_t>());
     }
 
@@ -8040,6 +8188,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Map& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("map") != j.end() && !j.at("map").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_map(j.at("map").get<int64_t>());
     }
 
@@ -8050,6 +8199,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, MetadataPropertyHandling& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("metadata_property_handling") != j.end() && !j.at("metadata_property_handling").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_metadata_property_handling(j.at("metadata_property_handling").get<int64_t>());
     }
 
@@ -8060,6 +8210,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Mutating& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("mutating") != j.end() && !j.at("mutating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mutating(j.at("mutating").get<int64_t>());
     }
 
@@ -8070,6 +8221,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Native& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("native") != j.end() && !j.at("native").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_native(j.at("native").get<int64_t>());
     }
 
@@ -8080,6 +8232,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Newtonsoft& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("newtonsoft") != j.end() && !j.at("newtonsoft").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_newtonsoft(j.at("newtonsoft").get<int64_t>());
     }
 
@@ -8090,6 +8243,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Nil& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("nil") != j.end() && !j.at("nil").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nil(j.at("nil").get<int64_t>());
     }
 
@@ -8100,6 +8254,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, No& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("NO") != j.end() && !j.at("NO").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_no(j.at("NO").get<int64_t>());
     }
 
@@ -8110,6 +8265,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Nonatomic& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("nonatomic") != j.end() && !j.at("nonatomic").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nonatomic(j.at("nonatomic").get<int64_t>());
     }
 
@@ -8120,6 +8276,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, None& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("None") != j.end() && !j.at("None").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_none(j.at("None").get<int64_t>());
     }
 
@@ -8130,6 +8287,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Nonlocal& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("nonlocal") != j.end() && !j.at("nonlocal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nonlocal(j.at("nonlocal").get<int64_t>());
     }
 
@@ -8140,6 +8298,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Nonmutating& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("nonmutating") != j.end() && !j.at("nonmutating").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nonmutating(j.at("nonmutating").get<int64_t>());
     }
 
@@ -8150,6 +8309,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, NsString& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("NSString") != j.end() && !j.at("NSString").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ns_string(j.at("NSString").get<int64_t>());
     }
 
@@ -8160,6 +8320,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Null& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("NULL") != j.end() && !j.at("NULL").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("NULL").get<int64_t>());
     }
 
@@ -8170,6 +8331,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Number& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(j.at("number").get<int64_t>());
     }
 
@@ -8180,6 +8342,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Long& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("long") != j.end() && !j.at("long").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_long_long(j.at("long").get<int64_t>());
     }
 
@@ -8190,6 +8353,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Module& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("module") != j.end() && !j.at("module").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_module_module(j.at("module").get<int64_t>());
     }
 
@@ -8200,6 +8364,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Mutable& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("mutable") != j.end() && !j.at("mutable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_mutable_mutable(j.at("mutable").get<int64_t>());
     }
 
@@ -8210,6 +8375,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Namespace& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("namespace") != j.end() && !j.at("namespace").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_namespace_namespace(j.at("namespace").get<int64_t>());
     }
 
@@ -8220,6 +8386,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, New& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("new") != j.end() && !j.at("new").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_new_new(j.at("new").get<int64_t>());
     }
 
@@ -8230,6 +8397,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Noexcept& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("noexcept") != j.end() && !j.at("noexcept").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_noexcept_noexcept(j.at("noexcept").get<int64_t>());
     }
 
@@ -8240,6 +8408,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, NoneClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("none") != j.end() && !j.at("none").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_none(j.at("none").get<int64_t>());
     }
 
@@ -8250,6 +8419,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Not& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("not") != j.end() && !j.at("not").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_not_not(j.at("not").get<int64_t>());
     }
 
@@ -8260,6 +8430,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, NotEq& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("not_eq") != j.end() && !j.at("not_eq").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_not_eq_not_eq(j.at("not_eq").get<int64_t>());
     }
 
@@ -8270,6 +8441,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, NullClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("null") != j.end() && !j.at("null").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_null(j.at("null").get<int64_t>());
     }
 
@@ -8280,6 +8452,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Nullptr& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("nullptr") != j.end() && !j.at("nullptr").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_nullptr_nullptr(j.at("nullptr").get<int64_t>());
     }
 
@@ -8290,6 +8463,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Operator& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("operator") != j.end() && !j.at("operator").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_operator_operator(j.at("operator").get<int64_t>());
     }
 
@@ -8300,6 +8474,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Or& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("or") != j.end() && !j.at("or").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_or_or(j.at("or").get<int64_t>());
     }
 
@@ -8310,6 +8485,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, OrEq& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("or_eq") != j.end() && !j.at("or_eq").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_or_eq_or_eq(j.at("or_eq").get<int64_t>());
     }
 
@@ -8320,6 +8496,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Override& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("override") != j.end() && !j.at("override").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_override_override(j.at("override").get<int64_t>());
     }
 
@@ -8330,6 +8507,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Private& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("private") != j.end() && !j.at("private").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_private_private(j.at("private").get<int64_t>());
     }
 
@@ -8340,6 +8518,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Protected& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("protected") != j.end() && !j.at("protected").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_protected_protected(j.at("protected").get<int64_t>());
     }
 
@@ -8350,6 +8529,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, ProtocolClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("protocol") != j.end() && !j.at("protocol").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_protocol(j.at("protocol").get<int64_t>());
     }
 
@@ -8360,6 +8540,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Object& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("object") != j.end() && !j.at("object").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_object(j.at("object").get<int64_t>());
     }
 
@@ -8370,6 +8551,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Of& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("of") != j.end() && !j.at("of").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_of(j.at("of").get<int64_t>());
     }
 
@@ -8380,6 +8562,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Oneway& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("oneway") != j.end() && !j.at("oneway").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_oneway(j.at("oneway").get<int64_t>());
     }
 
@@ -8390,6 +8573,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Open& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("open") != j.end() && !j.at("open").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_open(j.at("open").get<int64_t>());
     }
 
@@ -8400,6 +8584,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Optional& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("optional") != j.end() && !j.at("optional").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_optional(j.at("optional").get<int64_t>());
     }
 
@@ -8410,6 +8595,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Out& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("out") != j.end() && !j.at("out").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_out(j.at("out").get<int64_t>());
     }
 
@@ -8420,6 +8606,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Package& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("package") != j.end() && !j.at("package").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_package(j.at("package").get<int64_t>());
     }
 
@@ -8430,6 +8617,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Params& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("params") != j.end() && !j.at("params").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_params(j.at("params").get<int64_t>());
     }
 
@@ -8440,6 +8628,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("pass") != j.end() && !j.at("pass").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pass(j.at("pass").get<int64_t>());
     }
 
@@ -8450,6 +8639,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Port& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("port") != j.end() && !j.at("port").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_port(j.at("port").get<int64_t>());
     }
 
@@ -8460,6 +8650,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Postfix& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("postfix") != j.end() && !j.at("postfix").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_postfix(j.at("postfix").get<int64_t>());
     }
 
@@ -8470,6 +8661,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Precedence& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("precedence") != j.end() && !j.at("precedence").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_precedence(j.at("precedence").get<int64_t>());
     }
 
@@ -8480,6 +8672,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Prefix& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("prefix") != j.end() && !j.at("prefix").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_prefix(j.at("prefix").get<int64_t>());
     }
 
@@ -8490,6 +8683,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Print& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("print") != j.end() && !j.at("print").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_print(j.at("print").get<int64_t>());
     }
 
@@ -8500,6 +8694,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, PrintMembers& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("printMembers") != j.end() && !j.at("printMembers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_print_members(j.at("printMembers").get<int64_t>());
     }
 
@@ -8510,6 +8705,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Printf& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("printf") != j.end() && !j.at("printf").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_printf(j.at("printf").get<int64_t>());
     }
 
@@ -8520,6 +8716,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Protocol& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Protocol") != j.end() && !j.at("Protocol").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_protocol(j.at("Protocol").get<int64_t>());
     }
 
@@ -8530,6 +8727,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Obj3& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dummy") != j.end() && !j.at("dummy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dummy(j.at("dummy").get<int64_t>());
         x.set_is(j.at("is").get<Is>());
         x.set_iterable(j.at("iterable").get<Iterable>());
@@ -8670,6 +8868,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Public& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("public") != j.end() && !j.at("public").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_public_public(j.at("public").get<int64_t>());
     }
 
@@ -8680,6 +8879,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Register& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("register") != j.end() && !j.at("register").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_register_register(j.at("register").get<int64_t>());
     }
 
@@ -8690,6 +8890,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, ReinterpretCast& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("reinterpret_cast") != j.end() && !j.at("reinterpret_cast").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_reinterpret_cast_reinterpret_cast(j.at("reinterpret_cast").get<int64_t>());
     }
 
@@ -8700,6 +8901,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Requires& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("requires") != j.end() && !j.at("requires").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_requires_requires(j.at("requires").get<int64_t>());
     }
 
@@ -8710,6 +8912,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Return& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("return") != j.end() && !j.at("return").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_return_return(j.at("return").get<int64_t>());
     }
 
@@ -8720,6 +8923,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, SelfClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("self") != j.end() && !j.at("self").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_self(j.at("self").get<int64_t>());
     }
 
@@ -8730,6 +8934,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Short& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("short") != j.end() && !j.at("short").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_short_short(j.at("short").get<int64_t>());
     }
 
@@ -8740,6 +8945,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Signed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("signed") != j.end() && !j.at("signed").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_signed_signed(j.at("signed").get<int64_t>());
     }
 
@@ -8750,6 +8956,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Sizeof& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("sizeof") != j.end() && !j.at("sizeof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sizeof_sizeof(j.at("sizeof").get<int64_t>());
     }
 
@@ -8760,6 +8967,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Static& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("static") != j.end() && !j.at("static").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_static_static(j.at("static").get<int64_t>());
     }
 
@@ -8770,6 +8978,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, StaticAssert& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("static_assert") != j.end() && !j.at("static_assert").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_static_assert_static_assert(j.at("static_assert").get<int64_t>());
     }
 
@@ -8780,6 +8989,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, StaticCast& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("static_cast") != j.end() && !j.at("static_cast").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_static_cast_static_cast(j.at("static_cast").get<int64_t>());
     }
 
@@ -8790,6 +9000,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Struct& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("struct") != j.end() && !j.at("struct").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_struct_struct(j.at("struct").get<int64_t>());
     }
 
@@ -8800,6 +9011,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Switch& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("switch") != j.end() && !j.at("switch").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_switch_switch(j.at("switch").get<int64_t>());
     }
 
@@ -8810,6 +9022,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Synchronized& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("synchronized") != j.end() && !j.at("synchronized").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_synchronized_synchronized(j.at("synchronized").get<int64_t>());
     }
 
@@ -8820,6 +9033,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Template& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("template") != j.end() && !j.at("template").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_template_template(j.at("template").get<int64_t>());
     }
 
@@ -8830,6 +9044,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, This& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("this") != j.end() && !j.at("this").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_this_this(j.at("this").get<int64_t>());
     }
 
@@ -8840,6 +9055,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, ThreadLocal& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("thread_local") != j.end() && !j.at("thread_local").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thread_local_thread_local(j.at("thread_local").get<int64_t>());
     }
 
@@ -8850,6 +9066,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Throw& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("throw") != j.end() && !j.at("throw").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_throw_throw(j.at("throw").get<int64_t>());
     }
 
@@ -8860,6 +9077,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, True& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("True") != j.end() && !j.at("True").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_true_true(j.at("True").get<int64_t>());
     }
 
@@ -8870,6 +9088,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Try& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("try") != j.end() && !j.at("try").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_try_try(j.at("try").get<int64_t>());
     }
 
@@ -8880,6 +9099,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TypeClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("type") != j.end() && !j.at("type").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_type(j.at("type").get<int64_t>());
     }
 
@@ -8890,6 +9110,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Typedef& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("typedef") != j.end() && !j.at("typedef").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_typedef_typedef(j.at("typedef").get<int64_t>());
     }
 
@@ -8900,6 +9121,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Typeid& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("typeid") != j.end() && !j.at("typeid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_typeid_typeid(j.at("typeid").get<int64_t>());
     }
 
@@ -8910,6 +9132,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Typename& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("typename") != j.end() && !j.at("typename").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_typename_typename(j.at("typename").get<int64_t>());
     }
 
@@ -8920,6 +9143,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TrueClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("true") != j.end() && !j.at("true").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_true_true(j.at("true").get<int64_t>());
     }
 
@@ -8930,6 +9154,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Quicktype& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("quicktype") != j.end() && !j.at("quicktype").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quicktype(j.at("quicktype").get<int64_t>());
     }
 
@@ -8940,6 +9165,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Raise& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("raise") != j.end() && !j.at("raise").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_raise(j.at("raise").get<int64_t>());
     }
 
@@ -8950,6 +9176,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Range& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("range") != j.end() && !j.at("range").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_range(j.at("range").get<int64_t>());
     }
 
@@ -8960,6 +9187,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Readonly& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("readonly") != j.end() && !j.at("readonly").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_readonly(j.at("readonly").get<int64_t>());
     }
 
@@ -8970,6 +9198,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Ref& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("ref") != j.end() && !j.at("ref").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ref(j.at("ref").get<int64_t>());
     }
 
@@ -8980,6 +9209,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Repeat& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("repeat") != j.end() && !j.at("repeat").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_repeat(j.at("repeat").get<int64_t>());
     }
 
@@ -8990,6 +9220,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Require& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("require") != j.end() && !j.at("require").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_require(j.at("require").get<int64_t>());
     }
 
@@ -9000,6 +9231,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Required& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("required") != j.end() && !j.at("required").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_required(j.at("required").get<int64_t>());
     }
 
@@ -9010,6 +9242,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Restrict& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("restrict") != j.end() && !j.at("restrict").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_restrict(j.at("restrict").get<int64_t>());
     }
 
@@ -9020,6 +9253,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Retain& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("retain") != j.end() && !j.at("retain").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_retain(j.at("retain").get<int64_t>());
     }
 
@@ -9030,6 +9264,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Rethrows& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("rethrows") != j.end() && !j.at("rethrows").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_rethrows(j.at("rethrows").get<int64_t>());
     }
 
@@ -9040,6 +9275,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Right& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("right") != j.end() && !j.at("right").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_right(j.at("right").get<int64_t>());
     }
 
@@ -9050,6 +9286,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Sbyte& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("sbyte") != j.end() && !j.at("sbyte").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sbyte(j.at("sbyte").get<int64_t>());
     }
 
@@ -9060,6 +9297,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Sealed& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("sealed") != j.end() && !j.at("sealed").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sealed(j.at("sealed").get<int64_t>());
     }
 
@@ -9070,6 +9308,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Sel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("SEL") != j.end() && !j.at("SEL").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_sel(j.at("SEL").get<int64_t>());
     }
 
@@ -9080,6 +9319,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Select& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("select") != j.end() && !j.at("select").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_select(j.at("select").get<int64_t>());
     }
 
@@ -9090,6 +9330,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Self& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Self") != j.end() && !j.at("Self").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_self(j.at("Self").get<int64_t>());
     }
 
@@ -9100,6 +9341,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Serialize& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("serialize") != j.end() && !j.at("serialize").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_serialize(j.at("serialize").get<int64_t>());
     }
 
@@ -9110,6 +9352,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Set& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("set") != j.end() && !j.at("set").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_set(j.at("set").get<int64_t>());
     }
 
@@ -9120,6 +9363,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Stackalloc& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("stackalloc") != j.end() && !j.at("stackalloc").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stackalloc(j.at("stackalloc").get<int64_t>());
     }
 
@@ -9130,6 +9374,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Strictfp& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("strictfp") != j.end() && !j.at("strictfp").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_strictfp(j.at("strictfp").get<int64_t>());
     }
 
@@ -9140,6 +9385,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, String& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("string") != j.end() && !j.at("string").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_string(j.at("string").get<int64_t>());
     }
 
@@ -9150,6 +9396,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Subscript& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("subscript") != j.end() && !j.at("subscript").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_subscript(j.at("subscript").get<int64_t>());
     }
 
@@ -9160,6 +9407,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Super& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("super") != j.end() && !j.at("super").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_super(j.at("super").get<int64_t>());
     }
 
@@ -9170,6 +9418,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Symbol& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("symbol") != j.end() && !j.at("symbol").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_symbol(j.at("symbol").get<int64_t>());
     }
 
@@ -9180,6 +9429,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, System& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("system") != j.end() && !j.at("system").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_system(j.at("system").get<int64_t>());
     }
 
@@ -9190,6 +9440,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Then& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("then") != j.end() && !j.at("then").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_then(j.at("then").get<int64_t>());
     }
 
@@ -9200,6 +9451,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Throws& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("throws") != j.end() && !j.at("throws").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_throws(j.at("throws").get<int64_t>());
     }
 
@@ -9210,6 +9462,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, ToJson& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("to_json") != j.end() && !j.at("to_json").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_to_json(j.at("to_json").get<int64_t>());
     }
 
@@ -9220,6 +9473,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("top_level") != j.end() && !j.at("top_level").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_top_level(j.at("top_level").get<int64_t>());
     }
 
@@ -9230,6 +9484,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Transient& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("transient") != j.end() && !j.at("transient").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_transient(j.at("transient").get<int64_t>());
     }
 
@@ -9240,6 +9495,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Type& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("Type") != j.end() && !j.at("Type").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_type(j.at("Type").get<int64_t>());
     }
 
@@ -9250,6 +9506,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Typealias& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("typealias") != j.end() && !j.at("typealias").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_typealias(j.at("typealias").get<int64_t>());
     }
 
@@ -9260,6 +9517,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Typeof& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("typeof") != j.end() && !j.at("typeof").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_typeof(j.at("typeof").get<int64_t>());
     }
 
@@ -9270,6 +9528,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Uint& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("uint") != j.end() && !j.at("uint").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_uint(j.at("uint").get<int64_t>());
     }
 
@@ -9280,6 +9539,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Ulong& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("ulong") != j.end() && !j.at("ulong").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ulong(j.at("ulong").get<int64_t>());
     }
 
@@ -9290,6 +9550,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Unchecked& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("unchecked") != j.end() && !j.at("unchecked").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unchecked(j.at("unchecked").get<int64_t>());
     }
 
@@ -9300,6 +9561,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Undefined& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("undefined") != j.end() && !j.at("undefined").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_undefined(j.at("undefined").get<int64_t>());
     }
 
@@ -9310,6 +9572,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Obj4& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dummy") != j.end() && !j.at("dummy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dummy(j.at("dummy").get<int64_t>());
         x.set_obj4_public(j.at("public").get<Public>());
         x.set_obj4_register(j.at("register").get<Register>());
@@ -9448,6 +9711,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Union& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("union") != j.end() && !j.at("union").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_union_union(j.at("union").get<int64_t>());
     }
 
@@ -9458,6 +9722,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Unsigned& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("unsigned") != j.end() && !j.at("unsigned").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsigned_unsigned(j.at("unsigned").get<int64_t>());
     }
 
@@ -9468,6 +9733,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Using& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("using") != j.end() && !j.at("using").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_using_using(j.at("using").get<int64_t>());
     }
 
@@ -9478,6 +9744,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Virtual& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("virtual") != j.end() && !j.at("virtual").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_virtual_virtual(j.at("virtual").get<int64_t>());
     }
 
@@ -9488,6 +9755,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Void& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("void") != j.end() && !j.at("void").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_void_void(j.at("void").get<int64_t>());
     }
 
@@ -9498,6 +9766,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Volatile& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("volatile") != j.end() && !j.at("volatile").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_volatile_volatile(j.at("volatile").get<int64_t>());
     }
 
@@ -9508,6 +9777,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, WcharT& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("wchar_t") != j.end() && !j.at("wchar_t").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_wchar_t_wchar_t(j.at("wchar_t").get<int64_t>());
     }
 
@@ -9518,6 +9788,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, While& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("while") != j.end() && !j.at("while").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_while_while(j.at("while").get<int64_t>());
     }
 
@@ -9528,6 +9799,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Xor& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("xor") != j.end() && !j.at("xor").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_xor_xor(j.at("xor").get<int64_t>());
     }
 
@@ -9538,6 +9810,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, XorEq& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("xor_eq") != j.end() && !j.at("xor_eq").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_xor_eq_xor_eq(j.at("xor_eq").get<int64_t>());
     }
 
@@ -9548,6 +9821,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Unowned& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("unowned") != j.end() && !j.at("unowned").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unowned(j.at("unowned").get<int64_t>());
     }
 
@@ -9558,6 +9832,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Unsafe& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("unsafe") != j.end() && !j.at("unsafe").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unsafe(j.at("unsafe").get<int64_t>());
     }
 
@@ -9568,6 +9843,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Ushort& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("ushort") != j.end() && !j.at("ushort").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ushort(j.at("ushort").get<int64_t>());
     }
 
@@ -9578,6 +9854,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Var& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("var") != j.end() && !j.at("var").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_var(j.at("var").get<int64_t>());
     }
 
@@ -9588,6 +9865,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Weak& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("weak") != j.end() && !j.at("weak").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_weak(j.at("weak").get<int64_t>());
     }
 
@@ -9598,6 +9876,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Where& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("where") != j.end() && !j.at("where").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_where(j.at("where").get<int64_t>());
     }
 
@@ -9608,6 +9887,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, WillSet& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("willSet") != j.end() && !j.at("willSet").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_will_set(j.at("willSet").get<int64_t>());
     }
 
@@ -9618,6 +9898,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, With& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("with") != j.end() && !j.at("with").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_with(j.at("with").get<int64_t>());
     }
 
@@ -9628,6 +9909,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Yes& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("YES") != j.end() && !j.at("YES").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_yes(j.at("YES").get<int64_t>());
     }
 
@@ -9638,6 +9920,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Yield& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("yield") != j.end() && !j.at("yield").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_yield(j.at("yield").get<int64_t>());
     }
 
@@ -9648,6 +9931,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Obj5& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dummy") != j.end() && !j.at("dummy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dummy(j.at("dummy").get<int64_t>());
         x.set_obj5_union(j.at("union").get<Union>());
         x.set_obj5_unsigned(j.at("unsigned").get<Unsigned>());
@@ -9698,6 +9982,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("dummy") != j.end() && !j.at("dummy").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_dummy(j.at("dummy").get<int64_t>());
         x.set_obj1(j.at("obj1").get<Obj1>());
         x.set_obj2(j.at("obj2").get<Obj2>());
diff --git a/base/cplusplus/test/inputs/json/priority/list.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/list.json/default/quicktype.hpp
index 8c23968..93e017e 100644
--- a/base/cplusplus/test/inputs/json/priority/list.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/list.json/default/quicktype.hpp
@@ -112,6 +112,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("data") != j.end() && !j.at("data").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_data(j.at("data").get<int64_t>());
         x.set_next(get_heap_optional<TopLevel>(j, "next"));
     }
diff --git a/base/cplusplus/test/inputs/json/priority/name-style.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/name-style.json/default/quicktype.hpp
index 647e488..047c3c8 100644
--- a/base/cplusplus/test/inputs/json/priority/name-style.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/name-style.json/default/quicktype.hpp
@@ -82,6 +82,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("anEasyOne") != j.end() && !j.at("anEasyOne").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_an_easy_one(j.at("anEasyOne").get<int64_t>());
         x.set_is_mnist_letter(j.at("isMNISTLetter").get<bool>());
         x.set_json_string(j.at("JSONString").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/priority/nbl-stats.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/nbl-stats.json/default/quicktype.hpp
index 976d26a..59ce0eb 100644
--- a/base/cplusplus/test/inputs/json/priority/nbl-stats.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/nbl-stats.json/default/quicktype.hpp
@@ -1441,13 +1441,16 @@ namespace quicktype {
         x.set_clock(j.at("clock").get<std::string>());
         x.set_competition_name(j.at("competitionName").get<std::string>());
         x.set_id(j.at("id").get<std::string>());
+        if (j.find("period") != j.end() && !j.at("period").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_period(j.at("period").get<int64_t>());
         x.set_period_type(j.at("periodType").get<PerType>());
         x.set_team1(j.at("team1").get<Team>());
         x.set_team1_name(j.at("team1Name").get<std::string>());
+        if (j.find("team1Score") != j.end() && !j.at("team1Score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_team1_score(j.at("team1Score").get<int64_t>());
         x.set_team2(j.at("team2").get<Team>());
         x.set_team2_name(j.at("team2Name").get<std::string>());
+        if (j.find("team2Score") != j.end() && !j.at("team2Score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_team2_score(j.at("team2Score").get<int64_t>());
     }
 
@@ -1478,19 +1481,27 @@ namespace quicktype {
         x.set_international_family_name_initial(get_stack_optional<FamilyNameInitial>(j, "internationalFamilyNameInitial"));
         x.set_international_first_name(get_stack_optional<std::string>(j, "internationalFirstName"));
         x.set_international_first_name_initial(get_stack_optional<FirstNameInitial>(j, "internationalFirstNameInitial"));
+        if (j.find("lead") != j.end() && !j.at("lead").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lead(j.at("lead").get<int64_t>());
+        if (j.find("period") != j.end() && !j.at("period").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_period(j.at("period").get<int64_t>());
         x.set_period_type(j.at("periodType").get<PerType>());
         x.set_player(j.at("player").get<std::string>());
+        if (j.find("pno") != j.end() && !j.at("pno").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pno(j.at("pno").get<int64_t>());
         x.set_qualifier(j.at("qualifier").get<std::string>());
+        if (j.find("s1") != j.end() && !j.at("s1").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s1(j.at("s1").get<int64_t>());
+        if (j.find("s2") != j.end() && !j.at("s2").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s2(j.at("s2").get<int64_t>());
         x.set_scoreboard_name(get_stack_optional<ScoreboardName>(j, "scoreboardName"));
+        if (j.find("scoring") != j.end() && !j.at("scoring").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_scoring(j.at("scoring").get<int64_t>());
         x.set_shirt_number(j.at("shirtNumber").get<std::string>());
         x.set_sub_type(j.at("subType").get<std::string>());
+        if (j.find("success") != j.end() && !j.at("success").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_success(j.at("success").get<int64_t>());
+        if (j.find("tno") != j.end() && !j.at("tno").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tno(j.at("tno").get<int64_t>());
     }
 
@@ -1525,6 +1536,7 @@ namespace quicktype {
     inline void from_json(const json & j, Time& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_gt(j.at("gt").get<std::string>());
+        if (j.find("per") != j.end() && !j.at("per").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_per(j.at("per").get<int64_t>());
         x.set_per_type(j.at("perType").get<PerType>());
     }
@@ -1548,15 +1560,19 @@ namespace quicktype {
         x.set_international_first_name(get_stack_optional<std::string>(j, "internationalFirstName"));
         x.set_international_first_name_initial(get_stack_optional<FirstNameInitial>(j, "internationalFirstNameInitial"));
         x.set_name(get_stack_optional<std::string>(j, "name"));
+        if (j.find("per") != j.end() && !j.at("per").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_per(get_stack_optional<int64_t>(j, "per"));
         x.set_per_type(get_stack_optional<PerType>(j, "perType"));
         x.set_player(get_stack_optional<std::string>(j, "player"));
+        if (j.find("pno") != j.end() && !j.at("pno").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pno(j.at("pno").get<int64_t>());
         x.set_scoreboard_name(get_stack_optional<ScoreboardName>(j, "scoreboardName"));
         x.set_shirt_number(j.at("shirtNumber").get<std::string>());
         x.set_summary(get_stack_optional<std::string>(j, "summary"));
         x.set_times(get_stack_optional<std::vector<Time>>(j, "times"));
+        if (j.find("tno") != j.end() && !j.at("tno").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tno(j.at("tno").get<int64_t>());
+        if (j.find("tot") != j.end() && !j.at("tot").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot(get_stack_optional<int64_t>(j, "tot"));
     }
 
@@ -1630,15 +1646,22 @@ namespace quicktype {
 
     inline void from_json(const json & j, Pl& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("active") != j.end() && !j.at("active").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_active(j.at("active").get<int64_t>());
+        if (j.find("captain") != j.end() && !j.at("captain").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_captain(get_stack_optional<int64_t>(j, "captain"));
         x.set_comp(get_stack_optional<Comp>(j, "comp"));
+        if (j.find("eff_1") != j.end() && !j.at("eff_1").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eff_1(j.at("eff_1").get<int64_t>());
+        if (j.find("eff_2") != j.end() && !j.at("eff_2").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eff_2(j.at("eff_2").get<int64_t>());
         x.set_eff_3(j.at("eff_3").get<double>());
         x.set_eff_4(j.at("eff_4").get<double>());
+        if (j.find("eff_5") != j.end() && !j.at("eff_5").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eff_5(j.at("eff_5").get<int64_t>());
+        if (j.find("eff_6") != j.end() && !j.at("eff_6").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eff_6(j.at("eff_6").get<int64_t>());
+        if (j.find("eff_7") != j.end() && !j.at("eff_7").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_eff_7(j.at("eff_7").get<int64_t>());
         x.set_family_name(j.at("familyName").get<std::string>());
         x.set_family_name_initial(j.at("familyNameInitial").get<FamilyNameInitial>());
@@ -1650,35 +1673,63 @@ namespace quicktype {
         x.set_international_first_name_initial(j.at("internationalFirstNameInitial").get<FirstNameInitial>());
         x.set_name(j.at("name").get<std::string>());
         x.set_playing_position(j.at("playingPosition").get<std::string>());
+        if (j.find("sAssists") != j.end() && !j.at("sAssists").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_assists(j.at("sAssists").get<int64_t>());
+        if (j.find("sBlocks") != j.end() && !j.at("sBlocks").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_blocks(j.at("sBlocks").get<int64_t>());
+        if (j.find("sBlocksReceived") != j.end() && !j.at("sBlocksReceived").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_blocks_received(j.at("sBlocksReceived").get<int64_t>());
+        if (j.find("sFieldGoalsAttempted") != j.end() && !j.at("sFieldGoalsAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_field_goals_attempted(j.at("sFieldGoalsAttempted").get<int64_t>());
+        if (j.find("sFieldGoalsMade") != j.end() && !j.at("sFieldGoalsMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_field_goals_made(j.at("sFieldGoalsMade").get<int64_t>());
+        if (j.find("sFieldGoalsPercentage") != j.end() && !j.at("sFieldGoalsPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_field_goals_percentage(j.at("sFieldGoalsPercentage").get<int64_t>());
+        if (j.find("sFoulsOn") != j.end() && !j.at("sFoulsOn").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_fouls_on(j.at("sFoulsOn").get<int64_t>());
+        if (j.find("sFoulsPersonal") != j.end() && !j.at("sFoulsPersonal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_fouls_personal(j.at("sFoulsPersonal").get<int64_t>());
+        if (j.find("sFreeThrowsAttempted") != j.end() && !j.at("sFreeThrowsAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_free_throws_attempted(j.at("sFreeThrowsAttempted").get<int64_t>());
+        if (j.find("sFreeThrowsMade") != j.end() && !j.at("sFreeThrowsMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_free_throws_made(j.at("sFreeThrowsMade").get<int64_t>());
+        if (j.find("sFreeThrowsPercentage") != j.end() && !j.at("sFreeThrowsPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_free_throws_percentage(j.at("sFreeThrowsPercentage").get<int64_t>());
         x.set_s_minutes(j.at("sMinutes").get<SMinutes>());
+        if (j.find("sPlusMinusPoints") != j.end() && !j.at("sPlusMinusPoints").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_plus_minus_points(j.at("sPlusMinusPoints").get<int64_t>());
+        if (j.find("sPoints") != j.end() && !j.at("sPoints").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_points(j.at("sPoints").get<int64_t>());
+        if (j.find("sPointsFastBreak") != j.end() && !j.at("sPointsFastBreak").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_points_fast_break(j.at("sPointsFastBreak").get<int64_t>());
+        if (j.find("sPointsInThePaint") != j.end() && !j.at("sPointsInThePaint").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_points_in_the_paint(j.at("sPointsInThePaint").get<int64_t>());
+        if (j.find("sPointsSecondChance") != j.end() && !j.at("sPointsSecondChance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_points_second_chance(j.at("sPointsSecondChance").get<int64_t>());
+        if (j.find("sReboundsDefensive") != j.end() && !j.at("sReboundsDefensive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_rebounds_defensive(j.at("sReboundsDefensive").get<int64_t>());
+        if (j.find("sReboundsOffensive") != j.end() && !j.at("sReboundsOffensive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_rebounds_offensive(j.at("sReboundsOffensive").get<int64_t>());
+        if (j.find("sReboundsTotal") != j.end() && !j.at("sReboundsTotal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_rebounds_total(j.at("sReboundsTotal").get<int64_t>());
+        if (j.find("sSteals") != j.end() && !j.at("sSteals").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_steals(j.at("sSteals").get<int64_t>());
+        if (j.find("sThreePointersAttempted") != j.end() && !j.at("sThreePointersAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_three_pointers_attempted(j.at("sThreePointersAttempted").get<int64_t>());
+        if (j.find("sThreePointersMade") != j.end() && !j.at("sThreePointersMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_three_pointers_made(j.at("sThreePointersMade").get<int64_t>());
+        if (j.find("sThreePointersPercentage") != j.end() && !j.at("sThreePointersPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_three_pointers_percentage(j.at("sThreePointersPercentage").get<int64_t>());
+        if (j.find("sTurnovers") != j.end() && !j.at("sTurnovers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_turnovers(j.at("sTurnovers").get<int64_t>());
+        if (j.find("sTwoPointersAttempted") != j.end() && !j.at("sTwoPointersAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_two_pointers_attempted(j.at("sTwoPointersAttempted").get<int64_t>());
+        if (j.find("sTwoPointersMade") != j.end() && !j.at("sTwoPointersMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_two_pointers_made(j.at("sTwoPointersMade").get<int64_t>());
+        if (j.find("sTwoPointersPercentage") != j.end() && !j.at("sTwoPointersPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_s_two_pointers_percentage(j.at("sTwoPointersPercentage").get<int64_t>());
         x.set_shirt_number(j.at("shirtNumber").get<std::string>());
+        if (j.find("starter") != j.end() && !j.at("starter").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_starter(j.at("starter").get<int64_t>());
     }
 
@@ -1739,16 +1790,23 @@ namespace quicktype {
     inline void from_json(const json & j, Shot& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_action_type(j.at("actionType").get<ActionType>());
+        if (j.find("p") != j.end() && !j.at("p").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_p(j.at("p").get<int64_t>());
+        if (j.find("per") != j.end() && !j.at("per").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_per(j.at("per").get<int64_t>());
         x.set_per_type(j.at("perType").get<PerType>());
         x.set_player(j.at("player").get<std::string>());
+        if (j.find("pno") != j.end() && !j.at("pno").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_pno(j.at("pno").get<int64_t>());
+        if (j.find("r") != j.end() && !j.at("r").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_r(j.at("r").get<int64_t>());
         x.set_shirt_number(j.at("shirtNumber").get<std::string>());
         x.set_sub_type(j.at("subType").get<SubType>());
+        if (j.find("tno") != j.end() && !j.at("tno").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tno(j.at("tno").get<int64_t>());
+        if (j.find("x") != j.end() && !j.at("x").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_x(j.at("x").get<int64_t>());
+        if (j.find("y") != j.end() && !j.at("y").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_y(j.at("y").get<int64_t>());
     }
 
@@ -1772,68 +1830,120 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_code(j.at("code").get<std::string>());
         x.set_code_international(j.at("codeInternational").get<std::string>());
+        if (j.find("fouls") != j.end() && !j.at("fouls").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_fouls(j.at("fouls").get<int64_t>());
+        if (j.find("full_score") != j.end() && !j.at("full_score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_full_score(j.at("full_score").get<int64_t>());
         x.set_lds(j.at("lds").get<Lds>());
         x.set_logo(j.at("logo").get<std::string>());
         x.set_name(j.at("name").get<std::string>());
         x.set_name_international(j.at("nameInternational").get<std::string>());
+        if (j.find("p1_score") != j.end() && !j.at("p1_score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_p1_score(j.at("p1_score").get<int64_t>());
+        if (j.find("p2_score") != j.end() && !j.at("p2_score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_p2_score(j.at("p2_score").get<int64_t>());
+        if (j.find("p3_score") != j.end() && !j.at("p3_score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_p3_score(j.at("p3_score").get<int64_t>());
+        if (j.find("p4_score") != j.end() && !j.at("p4_score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_p4_score(j.at("p4_score").get<int64_t>());
         x.set_pl(j.at("pl").get<std::map<std::string, Pl>>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_scoring(j.at("scoring").get<std::vector<Scorer>>());
         x.set_short_name(j.at("shortName").get<std::string>());
         x.set_short_name_international(j.at("shortNameInternational").get<std::string>());
         x.set_shot(j.at("shot").get<std::vector<Shot>>());
+        if (j.find("timeouts") != j.end() && !j.at("timeouts").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_timeouts(j.at("timeouts").get<int64_t>());
+        if (j.find("tot_eff_1") != j.end() && !j.at("tot_eff_1").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_eff_1(j.at("tot_eff_1").get<int64_t>());
+        if (j.find("tot_eff_2") != j.end() && !j.at("tot_eff_2").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_eff_2(j.at("tot_eff_2").get<int64_t>());
         x.set_tot_eff_3(j.at("tot_eff_3").get<double>());
+        if (j.find("tot_eff_4") != j.end() && !j.at("tot_eff_4").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_eff_4(j.at("tot_eff_4").get<int64_t>());
+        if (j.find("tot_eff_5") != j.end() && !j.at("tot_eff_5").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_eff_5(j.at("tot_eff_5").get<int64_t>());
+        if (j.find("tot_eff_6") != j.end() && !j.at("tot_eff_6").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_eff_6(j.at("tot_eff_6").get<int64_t>());
+        if (j.find("tot_eff_7") != j.end() && !j.at("tot_eff_7").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_eff_7(j.at("tot_eff_7").get<int64_t>());
+        if (j.find("tot_sAssists") != j.end() && !j.at("tot_sAssists").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_assists(j.at("tot_sAssists").get<int64_t>());
+        if (j.find("tot_sBenchPoints") != j.end() && !j.at("tot_sBenchPoints").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_bench_points(j.at("tot_sBenchPoints").get<int64_t>());
+        if (j.find("tot_sBiggestLead") != j.end() && !j.at("tot_sBiggestLead").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_biggest_lead(j.at("tot_sBiggestLead").get<int64_t>());
+        if (j.find("tot_sBiggestScoringRun") != j.end() && !j.at("tot_sBiggestScoringRun").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_biggest_scoring_run(j.at("tot_sBiggestScoringRun").get<int64_t>());
+        if (j.find("tot_sBlocks") != j.end() && !j.at("tot_sBlocks").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_blocks(j.at("tot_sBlocks").get<int64_t>());
+        if (j.find("tot_sBlocksReceived") != j.end() && !j.at("tot_sBlocksReceived").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_blocks_received(j.at("tot_sBlocksReceived").get<int64_t>());
+        if (j.find("tot_sFieldGoalsAttempted") != j.end() && !j.at("tot_sFieldGoalsAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_field_goals_attempted(j.at("tot_sFieldGoalsAttempted").get<int64_t>());
+        if (j.find("tot_sFieldGoalsMade") != j.end() && !j.at("tot_sFieldGoalsMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_field_goals_made(j.at("tot_sFieldGoalsMade").get<int64_t>());
+        if (j.find("tot_sFieldGoalsPercentage") != j.end() && !j.at("tot_sFieldGoalsPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_field_goals_percentage(j.at("tot_sFieldGoalsPercentage").get<int64_t>());
+        if (j.find("tot_sFoulsOn") != j.end() && !j.at("tot_sFoulsOn").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_fouls_on(j.at("tot_sFoulsOn").get<int64_t>());
+        if (j.find("tot_sFoulsPersonal") != j.end() && !j.at("tot_sFoulsPersonal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_fouls_personal(j.at("tot_sFoulsPersonal").get<int64_t>());
+        if (j.find("tot_sFoulsTeam") != j.end() && !j.at("tot_sFoulsTeam").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_fouls_team(j.at("tot_sFoulsTeam").get<int64_t>());
+        if (j.find("tot_sFreeThrowsAttempted") != j.end() && !j.at("tot_sFreeThrowsAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_free_throws_attempted(j.at("tot_sFreeThrowsAttempted").get<int64_t>());
+        if (j.find("tot_sFreeThrowsMade") != j.end() && !j.at("tot_sFreeThrowsMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_free_throws_made(j.at("tot_sFreeThrowsMade").get<int64_t>());
+        if (j.find("tot_sFreeThrowsPercentage") != j.end() && !j.at("tot_sFreeThrowsPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_free_throws_percentage(j.at("tot_sFreeThrowsPercentage").get<int64_t>());
+        if (j.find("tot_sLeadChanges") != j.end() && !j.at("tot_sLeadChanges").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_lead_changes(j.at("tot_sLeadChanges").get<int64_t>());
+        if (j.find("tot_sMinutes") != j.end() && !j.at("tot_sMinutes").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_minutes(j.at("tot_sMinutes").get<int64_t>());
+        if (j.find("tot_sPoints") != j.end() && !j.at("tot_sPoints").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_points(j.at("tot_sPoints").get<int64_t>());
+        if (j.find("tot_sPointsFastBreak") != j.end() && !j.at("tot_sPointsFastBreak").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_points_fast_break(j.at("tot_sPointsFastBreak").get<int64_t>());
+        if (j.find("tot_sPointsFromTurnovers") != j.end() && !j.at("tot_sPointsFromTurnovers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_points_from_turnovers(j.at("tot_sPointsFromTurnovers").get<int64_t>());
+        if (j.find("tot_sPointsInThePaint") != j.end() && !j.at("tot_sPointsInThePaint").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_points_in_the_paint(j.at("tot_sPointsInThePaint").get<int64_t>());
+        if (j.find("tot_sPointsSecondChance") != j.end() && !j.at("tot_sPointsSecondChance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_points_second_chance(j.at("tot_sPointsSecondChance").get<int64_t>());
+        if (j.find("tot_sReboundsDefensive") != j.end() && !j.at("tot_sReboundsDefensive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_rebounds_defensive(j.at("tot_sReboundsDefensive").get<int64_t>());
+        if (j.find("tot_sReboundsOffensive") != j.end() && !j.at("tot_sReboundsOffensive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_rebounds_offensive(j.at("tot_sReboundsOffensive").get<int64_t>());
+        if (j.find("tot_sReboundsTeam") != j.end() && !j.at("tot_sReboundsTeam").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_rebounds_team(j.at("tot_sReboundsTeam").get<int64_t>());
+        if (j.find("tot_sReboundsTeamDefensive") != j.end() && !j.at("tot_sReboundsTeamDefensive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_rebounds_team_defensive(j.at("tot_sReboundsTeamDefensive").get<int64_t>());
+        if (j.find("tot_sReboundsTeamOffensive") != j.end() && !j.at("tot_sReboundsTeamOffensive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_rebounds_team_offensive(j.at("tot_sReboundsTeamOffensive").get<int64_t>());
+        if (j.find("tot_sReboundsTotal") != j.end() && !j.at("tot_sReboundsTotal").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_rebounds_total(j.at("tot_sReboundsTotal").get<int64_t>());
+        if (j.find("tot_sSteals") != j.end() && !j.at("tot_sSteals").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_steals(j.at("tot_sSteals").get<int64_t>());
+        if (j.find("tot_sThreePointersAttempted") != j.end() && !j.at("tot_sThreePointersAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_three_pointers_attempted(j.at("tot_sThreePointersAttempted").get<int64_t>());
+        if (j.find("tot_sThreePointersMade") != j.end() && !j.at("tot_sThreePointersMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_three_pointers_made(j.at("tot_sThreePointersMade").get<int64_t>());
+        if (j.find("tot_sThreePointersPercentage") != j.end() && !j.at("tot_sThreePointersPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_three_pointers_percentage(j.at("tot_sThreePointersPercentage").get<int64_t>());
         x.set_tot_s_time_leading(j.at("tot_sTimeLeading").get<double>());
+        if (j.find("tot_sTimesScoresLevel") != j.end() && !j.at("tot_sTimesScoresLevel").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_times_scores_level(j.at("tot_sTimesScoresLevel").get<int64_t>());
+        if (j.find("tot_sTurnovers") != j.end() && !j.at("tot_sTurnovers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_turnovers(j.at("tot_sTurnovers").get<int64_t>());
+        if (j.find("tot_sTurnoversTeam") != j.end() && !j.at("tot_sTurnoversTeam").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_turnovers_team(j.at("tot_sTurnoversTeam").get<int64_t>());
+        if (j.find("tot_sTwoPointersAttempted") != j.end() && !j.at("tot_sTwoPointersAttempted").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_two_pointers_attempted(j.at("tot_sTwoPointersAttempted").get<int64_t>());
+        if (j.find("tot_sTwoPointersMade") != j.end() && !j.at("tot_sTwoPointersMade").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_two_pointers_made(j.at("tot_sTwoPointersMade").get<int64_t>());
+        if (j.find("tot_sTwoPointersPercentage") != j.end() && !j.at("tot_sTwoPointersPercentage").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_tot_s_two_pointers_percentage(j.at("tot_sTwoPointersPercentage").get<int64_t>());
     }
 
@@ -1926,9 +2036,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("attendance") != j.end() && !j.at("attendance").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_attendance(j.at("attendance").get<int64_t>());
         x.set_clock(j.at("clock").get<std::string>());
+        if (j.find("disableMatch") != j.end() && !j.at("disableMatch").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_disable_match(j.at("disableMatch").get<int64_t>());
+        if (j.find("inOT") != j.end() && !j.at("inOT").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_in_ot(j.at("inOT").get<int64_t>());
         x.set_leaddata(j.at("leaddata").get<std::vector<std::vector<LeaddatumElement>>>());
         x.set_officials_referee1(j.at("officials_referee1").get<std::string>());
@@ -1936,14 +2049,19 @@ namespace quicktype {
         x.set_officials_referee3(j.at("officials_referee3").get<std::string>());
         x.set_othermatches(j.at("othermatches").get<std::vector<Othermatch>>());
         x.set_pbp(j.at("pbp").get<std::vector<Pbp>>());
+        if (j.find("period") != j.end() && !j.at("period").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_period(j.at("period").get<int64_t>());
+        if (j.find("periodLengthOVERTIME") != j.end() && !j.at("periodLengthOVERTIME").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_period_length_overtime(j.at("periodLengthOVERTIME").get<int64_t>());
+        if (j.find("periodLengthREGULAR") != j.end() && !j.at("periodLengthREGULAR").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_period_length_regular(j.at("periodLengthREGULAR").get<int64_t>());
         x.set_period_type(j.at("periodType").get<PerType>());
+        if (j.find("periodsMax") != j.end() && !j.at("periodsMax").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_periods_max(j.at("periodsMax").get<int64_t>());
         x.set_scorers(j.at("scorers").get<std::map<std::string, std::vector<Scorer>>>());
         x.set_timeline(j.at("timeline").get<std::vector<nlohmann::json>>());
         x.set_tm(j.at("tm").get<std::map<std::string, Tm>>());
+        if (j.find("totalTimeAdded") != j.end() && !j.at("totalTimeAdded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_time_added(j.at("totalTimeAdded").get<int64_t>());
         x.set_totallds(j.at("totallds").get<Totallds>());
     }
diff --git a/base/cplusplus/test/inputs/json/priority/nst-test-suite.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/nst-test-suite.json/default/quicktype.hpp
index 761e001..b00832c 100644
--- a/base/cplusplus/test/inputs/json/priority/nst-test-suite.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/nst-test-suite.json/default/quicktype.hpp
@@ -798,6 +798,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, YObjectEmptyKeyJson& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("") != j.end() && !j.at("").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_empty(j.at("").get<int64_t>());
     }
 
@@ -808,6 +809,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, YObjectEscapedNullInKeyJson& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find(([] { constexpr auto &s = "foo\u0000bar"; return std::string(s, sizeof(s) / sizeof(s[0]) - 1); }())) != j.end() && !j.at(([] { constexpr auto &s = "foo\u0000bar"; return std::string(s, sizeof(s) / sizeof(s[0]) - 1); }())).is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo_bar(j.at(([] { constexpr auto &s = "foo\u0000bar"; return std::string(s, sizeof(s) / sizeof(s[0]) - 1); }())).get<int64_t>());
     }
 
@@ -978,6 +980,7 @@ namespace quicktype {
         x.set_y_string_utf8_json(j.at("y_string_utf8.json").get<std::vector<std::string>>());
         x.set_y_string_with_del_character_json(j.at("y_string_with_del_character.json").get<std::vector<std::string>>());
         x.set_y_structure_lonely_false_json(j.at("y_structure_lonely_false.json").get<bool>());
+        if (j.find("y_structure_lonely_int.json") != j.end() && !j.at("y_structure_lonely_int.json").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_y_structure_lonely_int_json(j.at("y_structure_lonely_int.json").get<int64_t>());
         x.set_y_structure_lonely_negative_real_json(j.at("y_structure_lonely_negative_real.json").get<double>());
         x.set_y_structure_lonely_null_json(get_untyped(j, "y_structure_lonely_null.json"));
diff --git a/base/cplusplus/test/inputs/json/priority/omit-empty.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/omit-empty.json/default/quicktype.hpp
index a5338eb..1a25a4b 100644
--- a/base/cplusplus/test/inputs/json/priority/omit-empty.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/omit-empty.json/default/quicktype.hpp
@@ -131,6 +131,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Result& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("age") != j.end() && !j.at("age").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_age(j.at("age").get<int64_t>());
         x.set_name(get_untyped(j, "name"));
     }
diff --git a/base/cplusplus/test/inputs/json/priority/php-validation.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/php-validation.json/default/quicktype.hpp
index 33229ee..4bc86d4 100644
--- a/base/cplusplus/test/inputs/json/priority/php-validation.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/php-validation.json/default/quicktype.hpp
@@ -73,6 +73,7 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_boolean(j.at("boolean").get<bool>());
+        if (j.find("integer") != j.end() && !j.at("integer").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_integer(j.at("integer").get<int64_t>());
         x.set_integers(j.at("integers").get<std::vector<int64_t>>());
         x.set_number(j.at("number").get<double>());
diff --git a/base/cplusplus/test/inputs/json/priority/recursive.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/recursive.json/default/quicktype.hpp
index eea2066..8aab38e 100644
--- a/base/cplusplus/test/inputs/json/priority/recursive.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/recursive.json/default/quicktype.hpp
@@ -694,10 +694,12 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_concatenatecategoryname(j.at("concatenatecategoryname").get<bool>());
         x.set_hasoffer(j.at("hasoffer").get<bool>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_isfinal(j.at("isfinal").get<bool>());
         x.set_links(j.at("links").get<std::vector<LinkElement>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("parentcategoryid") != j.end() && !j.at("parentcategoryid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_parentcategoryid(j.at("parentcategoryid").get<int64_t>());
         x.set_thumbnail(j.at("thumbnail").get<CategoryThumbnail>());
     }
@@ -716,6 +718,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Eonandyear& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("lowestsetbit") != j.end() && !j.at("lowestsetbit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_lowestsetbit(j.at("lowestsetbit").get<int64_t>());
     }
 
@@ -740,16 +743,24 @@ namespace quicktype {
 
     inline void from_json(const json & j, Date& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("day") != j.end() && !j.at("day").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_day(j.at("day").get<int64_t>());
         x.set_eonandyear(j.at("eonandyear").get<Eonandyear>());
+        if (j.find("hour") != j.end() && !j.at("hour").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_hour(j.at("hour").get<int64_t>());
+        if (j.find("millisecond") != j.end() && !j.at("millisecond").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_millisecond(j.at("millisecond").get<int64_t>());
+        if (j.find("minute") != j.end() && !j.at("minute").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_minute(j.at("minute").get<int64_t>());
+        if (j.find("month") != j.end() && !j.at("month").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_month(j.at("month").get<int64_t>());
+        if (j.find("second") != j.end() && !j.at("second").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_second(j.at("second").get<int64_t>());
+        if (j.find("timezone") != j.end() && !j.at("timezone").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_timezone(j.at("timezone").get<int64_t>());
         x.set_valid(j.at("valid").get<bool>());
         x.set_xmlschematype(j.at("xmlschematype").get<Xmlschematype>());
+        if (j.find("year") != j.end() && !j.at("year").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_year(j.at("year").get<int64_t>());
     }
 
@@ -772,8 +783,10 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_applicationid(j.at("applicationid").get<std::string>());
         x.set_applicationversion(j.at("applicationversion").get<std::string>());
+        if (j.find("code") != j.end() && !j.at("code").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_code(j.at("code").get<int64_t>());
         x.set_date(j.at("date").get<Date>());
+        if (j.find("elapsedtime") != j.end() && !j.at("elapsedtime").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_elapsedtime(j.at("elapsedtime").get<int64_t>());
         x.set_message(j.at("message").get<std::string>());
         x.set_status(j.at("status").get<std::string>());
@@ -803,6 +816,7 @@ namespace quicktype {
     inline void from_json(const json & j, Useraveragerating& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_links(j.at("links").get<std::vector<LinkElement>>());
+        if (j.find("numcomments") != j.end() && !j.at("numcomments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_numcomments(j.at("numcomments").get<int64_t>());
         x.set_rating(j.at("rating").get<std::string>());
     }
@@ -847,8 +861,10 @@ namespace quicktype {
     inline void from_json(const json & j, FormatsClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_formats(get_stack_optional<std::vector<Format>>(j, "formats"));
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -862,21 +878,26 @@ namespace quicktype {
 
     inline void from_json(const json & j, ProductProduct& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("categoryid") != j.end() && !j.at("categoryid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_categoryid(j.at("categoryid").get<int64_t>());
         x.set_currency(j.at("currency").get<Currency>());
         x.set_eco(j.at("eco").get<bool>());
         x.set_fulldescription(j.at("fulldescription").get<bool>());
         x.set_hasmetasearch(j.at("hasmetasearch").get<bool>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_links(j.at("links").get<std::vector<LinkElement>>());
+        if (j.find("numoffers") != j.end() && !j.at("numoffers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_numoffers(j.at("numoffers").get<int64_t>());
         x.set_pricemax(j.at("pricemax").get<std::string>());
         x.set_pricemin(j.at("pricemin").get<std::string>());
         x.set_productname(j.at("productname").get<std::string>());
+        if (j.find("quantity") != j.end() && !j.at("quantity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quantity(j.at("quantity").get<int64_t>());
         x.set_rating(j.at("rating").get<Rating>());
         x.set_specification(j.at("specification").get<Specification>());
         x.set_thumbnail(j.at("thumbnail").get<std::shared_ptr<FormatsClass>>());
+        if (j.find("totalsellers") != j.end() && !j.at("totalsellers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_totalsellers(j.at("totalsellers").get<int64_t>());
     }
 
@@ -915,12 +936,17 @@ namespace quicktype {
         x.set_category(j.at("category").get<Category>());
         x.set_details(j.at("details").get<Details>());
         x.set_match(j.at("match").get<std::string>());
+        if (j.find("page") != j.end() && !j.at("page").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_page(j.at("page").get<int64_t>());
         x.set_product(j.at("product").get<std::vector<ProductElement>>());
         x.set_schk(j.at("schk").get<bool>());
+        if (j.find("totallooseoffers") != j.end() && !j.at("totallooseoffers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_totallooseoffers(j.at("totallooseoffers").get<int64_t>());
+        if (j.find("totalpages") != j.end() && !j.at("totalpages").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_totalpages(j.at("totalpages").get<int64_t>());
+        if (j.find("totalresultsavailable") != j.end() && !j.at("totalresultsavailable").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_totalresultsavailable(j.at("totalresultsavailable").get<int64_t>());
+        if (j.find("totalresultsreturned") != j.end() && !j.at("totalresultsreturned").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_totalresultsreturned(j.at("totalresultsreturned").get<int64_t>());
     }
 
diff --git a/base/cplusplus/test/inputs/json/priority/uuids.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/priority/uuids.json/default/quicktype.hpp
index be2b4a7..4d2d2cf 100644
--- a/base/cplusplus/test/inputs/json/priority/uuids.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/priority/uuids.json/default/quicktype.hpp
@@ -79,6 +79,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_boolean_value(j.at("booleanValue").get<bool>());
         x.set_double_value(j.at("doubleValue").get<double>());
+        if (j.find("intValue") != j.end() && !j.at("intValue").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_int_value(j.at("intValue").get<int64_t>());
         x.set_string_value(j.at("stringValue").get<std::string>());
         x.set_uuid_value(j.at("uuidValue").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/samples/bitcoin-block.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/bitcoin-block.json/default/quicktype.hpp
index f1f46d7..63134f6 100644
--- a/base/cplusplus/test/inputs/json/samples/bitcoin-block.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/bitcoin-block.json/default/quicktype.hpp
@@ -72,9 +72,12 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("block_index") != j.end() && !j.at("block_index").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_block_index(j.at("block_index").get<int64_t>());
         x.set_hash(j.at("hash").get<std::string>());
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
+        if (j.find("time") != j.end() && !j.at("time").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_time(j.at("time").get<int64_t>());
         x.set_tx_indexes(j.at("txIndexes").get<std::vector<int64_t>>());
     }
diff --git a/base/cplusplus/test/inputs/json/samples/github-events.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/github-events.json/default/quicktype.hpp
index 896d67e..5588480 100644
--- a/base/cplusplus/test/inputs/json/samples/github-events.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/github-events.json/default/quicktype.hpp
@@ -1478,6 +1478,7 @@ namespace quicktype {
         x.set_avatar_url(j.at("avatar_url").get<std::string>());
         x.set_display_login(get_stack_optional<std::string>(j, "display_login"));
         x.set_gravatar_id(j.at("gravatar_id").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_login(j.at("login").get<std::string>());
         x.set_url(j.at("url").get<std::string>());
@@ -1502,6 +1503,7 @@ namespace quicktype {
         x.set_gists_url(j.at("gists_url").get<std::string>());
         x.set_gravatar_id(j.at("gravatar_id").get<std::string>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_login(j.at("login").get<std::string>());
         x.set_organizations_url(j.at("organizations_url").get<std::string>());
@@ -1540,6 +1542,7 @@ namespace quicktype {
         x.set_body(j.at("body").get<std::string>());
         x.set_created_at(j.at("created_at").get<std::string>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_issue_url(j.at("issue_url").get<std::string>());
         x.set_updated_at(j.at("updated_at").get<std::string>());
@@ -1592,6 +1595,7 @@ namespace quicktype {
     inline void from_json(const json & j, Label& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_color(j.at("color").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_label_default(j.at("default").get<bool>());
         x.set_name(j.at("name").get<std::string>());
@@ -1610,15 +1614,19 @@ namespace quicktype {
     inline void from_json(const json & j, Milestone& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_closed_at(get_untyped(j, "closed_at"));
+        if (j.find("closed_issues") != j.end() && !j.at("closed_issues").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_closed_issues(j.at("closed_issues").get<int64_t>());
         x.set_created_at(j.at("created_at").get<std::string>());
         x.set_creator(j.at("creator").get<User>());
         x.set_description(j.at("description").get<std::string>());
         x.set_due_on(get_stack_optional<std::string>(j, "due_on"));
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_labels_url(j.at("labels_url").get<std::string>());
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(j.at("number").get<int64_t>());
+        if (j.find("open_issues") != j.end() && !j.at("open_issues").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_open_issues(j.at("open_issues").get<int64_t>());
         x.set_state(j.at("state").get<std::string>());
         x.set_title(j.at("title").get<std::string>());
@@ -1667,16 +1675,19 @@ namespace quicktype {
         x.set_assignees(j.at("assignees").get<std::vector<nlohmann::json>>());
         x.set_body(j.at("body").get<std::string>());
         x.set_closed_at(get_stack_optional<std::string>(j, "closed_at"));
+        if (j.find("comments") != j.end() && !j.at("comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_comments(j.at("comments").get<int64_t>());
         x.set_comments_url(j.at("comments_url").get<std::string>());
         x.set_created_at(j.at("created_at").get<std::string>());
         x.set_events_url(j.at("events_url").get<std::string>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_labels(j.at("labels").get<std::vector<Label>>());
         x.set_labels_url(j.at("labels_url").get<std::string>());
         x.set_locked(j.at("locked").get<bool>());
         x.set_milestone(get_stack_optional<Milestone>(j, "milestone"));
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(j.at("number").get<int64_t>());
         x.set_pull_request(get_stack_optional<IssuePullRequest>(j, "pull_request"));
         x.set_repository_url(j.at("repository_url").get<std::string>());
@@ -1733,7 +1744,9 @@ namespace quicktype {
         x.set_downloads_url(j.at("downloads_url").get<std::string>());
         x.set_events_url(j.at("events_url").get<std::string>());
         x.set_fork(j.at("fork").get<bool>());
+        if (j.find("forks") != j.end() && !j.at("forks").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_forks(j.at("forks").get<int64_t>());
+        if (j.find("forks_count") != j.end() && !j.at("forks_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_forks_count(j.at("forks_count").get<int64_t>());
         x.set_forks_url(j.at("forks_url").get<std::string>());
         x.set_full_name(j.at("full_name").get<std::string>());
@@ -1749,6 +1762,7 @@ namespace quicktype {
         x.set_homepage(j.at("homepage").get<std::string>());
         x.set_hooks_url(j.at("hooks_url").get<std::string>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_issue_comment_url(j.at("issue_comment_url").get<std::string>());
         x.set_issue_events_url(j.at("issue_events_url").get<std::string>());
@@ -1762,15 +1776,19 @@ namespace quicktype {
         x.set_mirror_url(get_untyped(j, "mirror_url"));
         x.set_name(j.at("name").get<std::string>());
         x.set_notifications_url(j.at("notifications_url").get<std::string>());
+        if (j.find("open_issues") != j.end() && !j.at("open_issues").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_open_issues(j.at("open_issues").get<int64_t>());
+        if (j.find("open_issues_count") != j.end() && !j.at("open_issues_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_open_issues_count(j.at("open_issues_count").get<int64_t>());
         x.set_owner(j.at("owner").get<User>());
         x.set_pulls_url(j.at("pulls_url").get<std::string>());
         x.set_pushed_at(j.at("pushed_at").get<std::string>());
         x.set_releases_url(j.at("releases_url").get<std::string>());
         x.set_repo_private(j.at("private").get<bool>());
+        if (j.find("size") != j.end() && !j.at("size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_size(j.at("size").get<int64_t>());
         x.set_ssh_url(j.at("ssh_url").get<std::string>());
+        if (j.find("stargazers_count") != j.end() && !j.at("stargazers_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_stargazers_count(j.at("stargazers_count").get<int64_t>());
         x.set_stargazers_url(j.at("stargazers_url").get<std::string>());
         x.set_statuses_url(j.at("statuses_url").get<std::string>());
@@ -1782,7 +1800,9 @@ namespace quicktype {
         x.set_trees_url(j.at("trees_url").get<std::string>());
         x.set_updated_at(j.at("updated_at").get<std::string>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("watchers") != j.end() && !j.at("watchers").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_watchers(j.at("watchers").get<int64_t>());
+        if (j.find("watchers_count") != j.end() && !j.at("watchers_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_watchers_count(j.at("watchers_count").get<int64_t>());
     }
 
@@ -1913,22 +1933,28 @@ namespace quicktype {
 
     inline void from_json(const json & j, PayloadPullRequest& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("additions") != j.end() && !j.at("additions").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_additions(j.at("additions").get<int64_t>());
         x.set_assignee(get_untyped(j, "assignee"));
         x.set_assignees(j.at("assignees").get<std::vector<nlohmann::json>>());
         x.set_base(j.at("base").get<Base>());
         x.set_body(j.at("body").get<std::string>());
+        if (j.find("changed_files") != j.end() && !j.at("changed_files").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_changed_files(j.at("changed_files").get<int64_t>());
         x.set_closed_at(j.at("closed_at").get<std::string>());
+        if (j.find("comments") != j.end() && !j.at("comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_comments(j.at("comments").get<int64_t>());
         x.set_comments_url(j.at("comments_url").get<std::string>());
+        if (j.find("commits") != j.end() && !j.at("commits").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_commits(j.at("commits").get<int64_t>());
         x.set_commits_url(j.at("commits_url").get<std::string>());
         x.set_created_at(j.at("created_at").get<std::string>());
+        if (j.find("deletions") != j.end() && !j.at("deletions").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_deletions(j.at("deletions").get<int64_t>());
         x.set_diff_url(j.at("diff_url").get<std::string>());
         x.set_head(j.at("head").get<Base>());
         x.set_html_url(j.at("html_url").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_issue_url(j.at("issue_url").get<std::string>());
         x.set_links(j.at("_links").get<Links>());
@@ -1941,11 +1967,13 @@ namespace quicktype {
         x.set_merged_at(j.at("merged_at").get<std::string>());
         x.set_merged_by(j.at("merged_by").get<User>());
         x.set_milestone(get_untyped(j, "milestone"));
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(j.at("number").get<int64_t>());
         x.set_patch_url(j.at("patch_url").get<std::string>());
         x.set_rebaseable(get_untyped(j, "rebaseable"));
         x.set_requested_reviewers(j.at("requested_reviewers").get<std::vector<nlohmann::json>>());
         x.set_review_comment_url(j.at("review_comment_url").get<std::string>());
+        if (j.find("review_comments") != j.end() && !j.at("review_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_review_comments(j.at("review_comments").get<int64_t>());
         x.set_review_comments_url(j.at("review_comments_url").get<std::string>());
         x.set_state(j.at("state").get<std::string>());
@@ -2008,16 +2036,20 @@ namespace quicktype {
         x.set_comment(get_stack_optional<Comment>(j, "comment"));
         x.set_commits(get_stack_optional<std::vector<Commit>>(j, "commits"));
         x.set_description(get_stack_optional<std::string>(j, "description"));
+        if (j.find("distinct_size") != j.end() && !j.at("distinct_size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_distinct_size(get_stack_optional<int64_t>(j, "distinct_size"));
         x.set_head(get_stack_optional<std::string>(j, "head"));
         x.set_issue(get_stack_optional<Issue>(j, "issue"));
         x.set_master_branch(get_stack_optional<std::string>(j, "master_branch"));
+        if (j.find("number") != j.end() && !j.at("number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_number(get_stack_optional<int64_t>(j, "number"));
         x.set_pull_request(get_stack_optional<PayloadPullRequest>(j, "pull_request"));
+        if (j.find("push_id") != j.end() && !j.at("push_id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_push_id(get_stack_optional<int64_t>(j, "push_id"));
         x.set_pusher_type(get_stack_optional<std::string>(j, "pusher_type"));
         x.set_ref(get_stack_optional<std::string>(j, "ref"));
         x.set_ref_type(get_stack_optional<std::string>(j, "ref_type"));
+        if (j.find("size") != j.end() && !j.at("size").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_size(get_stack_optional<int64_t>(j, "size"));
     }
 
@@ -2043,6 +2075,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelRepo& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
         x.set_url(j.at("url").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/samples/kitchen-sink.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/kitchen-sink.json/default/quicktype.hpp
index 82d3815..09d894d 100644
--- a/base/cplusplus/test/inputs/json/samples/kitchen-sink.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/kitchen-sink.json/default/quicktype.hpp
@@ -283,6 +283,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, PurplePerson& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("intOrString") != j.end() && !j.at("intOrString").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_int_or_string(j.at("intOrString").get<int64_t>());
         x.set_name(j.at("name").get<std::string>());
     }
@@ -299,6 +300,7 @@ namespace quicktype {
         x.set_date_value(j.at("dateValue").get<std::string>());
         x.set_different_things(j.at("differentThings").get<std::vector<DifferentThingElement>>());
         x.set_double_value(j.at("doubleValue").get<double>());
+        if (j.find("intValue") != j.end() && !j.at("intValue").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_int_value(j.at("intValue").get<int64_t>());
         x.set_map_value(j.at("mapValue").get<std::map<std::string, std::optional<int64_t>>>());
         x.set_name_with_spaces(get_untyped(j, "name with spaces"));
diff --git a/base/cplusplus/test/inputs/json/samples/pokedex.json/boost-true--bed8626e10e6/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/pokedex.json/boost-true--bed8626e10e6/quicktype.hpp
index 0490a61..33e1f11 100644
--- a/base/cplusplus/test/inputs/json/samples/pokedex.json/boost-true--bed8626e10e6/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/pokedex.json/boost-true--bed8626e10e6/quicktype.hpp
@@ -253,9 +253,11 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_avg_spawns(j.at("avg_spawns").get<double>());
         x.set_candy(j.at("candy").get<std::string>());
+        if (j.find("candy_count") != j.end() && !j.at("candy_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_candy_count(get_stack_optional<int64_t>(j, "candy_count"));
         x.set_egg(j.at("egg").get<Egg>());
         x.set_height(j.at("height").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_img(j.at("img").get<std::string>());
         x.set_multipliers(get_stack_optional<std::vector<double>>(j, "multipliers"));
diff --git a/base/cplusplus/test/inputs/json/samples/pokedex.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/pokedex.json/default/quicktype.hpp
index 904df11..88c9d66 100644
--- a/base/cplusplus/test/inputs/json/samples/pokedex.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/pokedex.json/default/quicktype.hpp
@@ -252,9 +252,11 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_avg_spawns(j.at("avg_spawns").get<double>());
         x.set_candy(j.at("candy").get<std::string>());
+        if (j.find("candy_count") != j.end() && !j.at("candy_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_candy_count(get_stack_optional<int64_t>(j, "candy_count"));
         x.set_egg(j.at("egg").get<Egg>());
         x.set_height(j.at("height").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_img(j.at("img").get<std::string>());
         x.set_multipliers(get_stack_optional<std::vector<double>>(j, "multipliers"));
diff --git a/base/cplusplus/test/inputs/json/samples/reddit.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/reddit.json/default/quicktype.hpp
index ed16264..f027a3a 100644
--- a/base/cplusplus/test/inputs/json/samples/reddit.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/reddit.json/default/quicktype.hpp
@@ -694,8 +694,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Source& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -773,12 +775,16 @@ namespace quicktype {
         x.set_can_mod_post(j.at("can_mod_post").get<bool>());
         x.set_clicked(j.at("clicked").get<bool>());
         x.set_contest_mode(j.at("contest_mode").get<bool>());
+        if (j.find("created") != j.end() && !j.at("created").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created(j.at("created").get<int64_t>());
+        if (j.find("created_utc") != j.end() && !j.at("created_utc").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_created_utc(j.at("created_utc").get<int64_t>());
         x.set_distinguished(get_stack_optional<std::string>(j, "distinguished"));
         x.set_domain(j.at("domain").get<Domain>());
+        if (j.find("downs") != j.end() && !j.at("downs").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_downs(j.at("downs").get<int64_t>());
         x.set_edited(j.at("edited").get<bool>());
+        if (j.find("gilded") != j.end() && !j.at("gilded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_gilded(j.at("gilded").get<int64_t>());
         x.set_hidden(j.at("hidden").get<bool>());
         x.set_hide_score(j.at("hide_score").get<bool>());
@@ -793,6 +799,7 @@ namespace quicktype {
         x.set_media_embed(j.at("media_embed").get<MediaEmbed>());
         x.set_mod_reports(j.at("mod_reports").get<std::vector<nlohmann::json>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("num_comments") != j.end() && !j.at("num_comments").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_num_comments(j.at("num_comments").get<int64_t>());
         x.set_num_reports(get_untyped(j, "num_reports"));
         x.set_over_18(j.at("over_18").get<bool>());
@@ -804,6 +811,7 @@ namespace quicktype {
         x.set_removal_reason(get_untyped(j, "removal_reason"));
         x.set_report_reasons(get_untyped(j, "report_reasons"));
         x.set_saved(j.at("saved").get<bool>());
+        if (j.find("score") != j.end() && !j.at("score").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_score(j.at("score").get<int64_t>());
         x.set_secure_media(get_untyped(j, "secure_media"));
         x.set_secure_media_embed(j.at("secure_media_embed").get<MediaEmbed>());
@@ -817,9 +825,12 @@ namespace quicktype {
         x.set_subreddit_type(j.at("subreddit_type").get<SubredditType>());
         x.set_suggested_sort(get_untyped(j, "suggested_sort"));
         x.set_thumbnail(j.at("thumbnail").get<std::string>());
+        if (j.find("thumbnail_height") != j.end() && !j.at("thumbnail_height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_height(j.at("thumbnail_height").get<int64_t>());
+        if (j.find("thumbnail_width") != j.end() && !j.at("thumbnail_width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_thumbnail_width(j.at("thumbnail_width").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
+        if (j.find("ups") != j.end() && !j.at("ups").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_ups(j.at("ups").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
         x.set_user_reports(j.at("user_reports").get<std::vector<nlohmann::json>>());
diff --git a/base/cplusplus/test/inputs/json/samples/simple-object.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/simple-object.json/default/quicktype.hpp
index 1859e7d..3551adf 100644
--- a/base/cplusplus/test/inputs/json/samples/simple-object.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/simple-object.json/default/quicktype.hpp
@@ -62,6 +62,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("date") != j.end() && !j.at("date").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_date(j.at("date").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_validity(j.at("validity").get<bool>());
diff --git a/base/cplusplus/test/inputs/json/samples/spotify-album.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/spotify-album.json/default/quicktype.hpp
index 0be62df..6683ea7 100644
--- a/base/cplusplus/test/inputs/json/samples/spotify-album.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/spotify-album.json/default/quicktype.hpp
@@ -433,8 +433,10 @@ namespace quicktype {
 
     inline void from_json(const json & j, Image& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("height") != j.end() && !j.at("height").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_height(j.at("height").get<int64_t>());
         x.set_url(j.at("url").get<std::string>());
+        if (j.find("width") != j.end() && !j.at("width").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_width(j.at("width").get<int64_t>());
     }
 
@@ -449,7 +451,9 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_artists(j.at("artists").get<std::vector<Artist>>());
         x.set_available_markets(j.at("available_markets").get<std::vector<std::string>>());
+        if (j.find("disc_number") != j.end() && !j.at("disc_number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_disc_number(j.at("disc_number").get<int64_t>());
+        if (j.find("duration_ms") != j.end() && !j.at("duration_ms").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_duration_ms(j.at("duration_ms").get<int64_t>());
         x.set_external_urls(j.at("external_urls").get<ExternalUrls>());
         x.set_href(j.at("href").get<std::string>());
@@ -457,6 +461,7 @@ namespace quicktype {
         x.set_item_explicit(j.at("explicit").get<bool>());
         x.set_name(j.at("name").get<std::string>());
         x.set_preview_url(j.at("preview_url").get<std::string>());
+        if (j.find("track_number") != j.end() && !j.at("track_number").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_track_number(j.at("track_number").get<int64_t>());
         x.set_type(j.at("type").get<std::string>());
         x.set_uri(j.at("uri").get<std::string>());
@@ -483,10 +488,13 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_href(j.at("href").get<std::string>());
         x.set_items(j.at("items").get<std::vector<Item>>());
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
         x.set_next(get_untyped(j, "next"));
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
         x.set_previous(get_untyped(j, "previous"));
+        if (j.find("total") != j.end() && !j.at("total").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total(j.at("total").get<int64_t>());
     }
 
@@ -514,6 +522,7 @@ namespace quicktype {
         x.set_id(j.at("id").get<std::string>());
         x.set_images(j.at("images").get<std::vector<Image>>());
         x.set_name(j.at("name").get<std::string>());
+        if (j.find("popularity") != j.end() && !j.at("popularity").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_popularity(j.at("popularity").get<int64_t>());
         x.set_release_date(j.at("release_date").get<std::string>());
         x.set_release_date_precision(j.at("release_date_precision").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/samples/us-avg-temperatures.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/us-avg-temperatures.json/default/quicktype.hpp
index 524bc15..caa9af8 100644
--- a/base/cplusplus/test/inputs/json/samples/us-avg-temperatures.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/us-avg-temperatures.json/default/quicktype.hpp
@@ -124,6 +124,7 @@ namespace quicktype {
     inline void from_json(const json & j, Description& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_base_period(j.at("base_period").get<std::string>());
+        if (j.find("missing") != j.end() && !j.at("missing").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_missing(j.at("missing").get<int64_t>());
         x.set_title(j.at("title").get<std::string>());
         x.set_units(j.at("units").get<std::string>());
diff --git a/base/cplusplus/test/inputs/json/samples/us-senators.json/default/quicktype.hpp b/head/cplusplus/test/inputs/json/samples/us-senators.json/default/quicktype.hpp
index 34656fd..804dfc0 100644
--- a/base/cplusplus/test/inputs/json/samples/us-senators.json/default/quicktype.hpp
+++ b/head/cplusplus/test/inputs/json/samples/us-senators.json/default/quicktype.hpp
@@ -448,8 +448,11 @@ namespace quicktype {
 
     inline void from_json(const json & j, Meta& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("limit") != j.end() && !j.at("limit").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_limit(j.at("limit").get<int64_t>());
+        if (j.find("offset") != j.end() && !j.at("offset").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_offset(j.at("offset").get<int64_t>());
+        if (j.find("total_count") != j.end() && !j.at("total_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("total_count").get<int64_t>());
     }
 
@@ -482,6 +485,7 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_bioguideid(j.at("bioguideid").get<std::string>());
         x.set_birthday(j.at("birthday").get<std::string>());
+        if (j.find("cspanid") != j.end() && !j.at("cspanid").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_cspanid(j.at("cspanid").get<int64_t>());
         x.set_firstname(j.at("firstname").get<std::string>());
         x.set_gender(j.at("gender").get<Gender>());
diff --git a/base/cplusplus-multi-source/test/inputs/json/samples/pokedex.json/default/Generators.hpp b/head/cplusplus-multi-source/test/inputs/json/samples/pokedex.json/default/Generators.hpp
index a5ddba2..cc19d44 100644
--- a/base/cplusplus-multi-source/test/inputs/json/samples/pokedex.json/default/Generators.hpp
+++ b/head/cplusplus-multi-source/test/inputs/json/samples/pokedex.json/default/Generators.hpp
@@ -50,9 +50,11 @@ namespace quicktype {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_avg_spawns(j.at("avg_spawns").get<double>());
         x.set_candy(j.at("candy").get<std::string>());
+        if (j.find("candy_count") != j.end() && !j.at("candy_count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_candy_count(get_stack_optional<int64_t>(j, "candy_count"));
         x.set_egg(j.at("egg").get<Egg>());
         x.set_height(j.at("height").get<std::string>());
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
         x.set_img(j.at("img").get<std::string>());
         x.set_multipliers(get_stack_optional<std::vector<double>>(j, "multipliers"));
diff --git a/base/graphql-cplusplus/test/inputs/graphql/github2.graphql/default/quicktype.hpp b/head/graphql-cplusplus/test/inputs/graphql/github2.graphql/default/quicktype.hpp
index ca77a9f..65e748f 100644
--- a/base/graphql-cplusplus/test/inputs/graphql/github2.graphql/default/quicktype.hpp
+++ b/head/graphql-cplusplus/test/inputs/graphql/github2.graphql/default/quicktype.hpp
@@ -217,6 +217,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, RepositoryConnection& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("totalCount") != j.end() && !j.at("totalCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("totalCount").get<int64_t>());
         x.set_nodes(get_stack_optional<std::vector<std::optional<Repository>>>(j, "nodes"));
     }
diff --git a/base/graphql-cplusplus/test/inputs/graphql/github7.graphql/default/quicktype.hpp b/head/graphql-cplusplus/test/inputs/graphql/github7.graphql/default/quicktype.hpp
index b297115..2ed2879 100644
--- a/base/graphql-cplusplus/test/inputs/graphql/github7.graphql/default/quicktype.hpp
+++ b/head/graphql-cplusplus/test/inputs/graphql/github7.graphql/default/quicktype.hpp
@@ -260,6 +260,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, Connection& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("totalCount") != j.end() && !j.at("totalCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_total_count(j.at("totalCount").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/class-map-union.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/class-map-union.schema/default/quicktype.hpp
index 530c1c8..8c6df52 100644
--- a/base/schema-cplusplus/test/inputs/schema/class-map-union.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/class-map-union.schema/default/quicktype.hpp
@@ -137,6 +137,7 @@ struct adl_serializer<std::variant<bool, quicktype::UnionClass, double, std::str
 namespace quicktype {
     inline void from_json(const json & j, UnionClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("quux") != j.end() && !j.at("quux").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_quux(get_stack_optional<int64_t>(j, "quux"));
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/const-non-string.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/const-non-string.schema/default/quicktype.hpp
index 194523f..1ed763a 100644
--- a/base/schema-cplusplus/test/inputs/schema/const-non-string.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/const-non-string.schema/default/quicktype.hpp
@@ -77,6 +77,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("amount") != j.end() && !j.at("amount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_amount(j.at("amount").get<int64_t>());
         x.set_enabled(j.at("enabled").get<bool>());
         x.set_kind(j.at("kind").get<Kind>());
diff --git a/base/schema-cplusplus/test/inputs/schema/cut-enum.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/cut-enum.schema/default/quicktype.hpp
index dcbf488..94e8cb7 100644
--- a/base/schema-cplusplus/test/inputs/schema/cut-enum.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/cut-enum.schema/default/quicktype.hpp
@@ -52,6 +52,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("foo") != j.end() && !j.at("foo").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("foo").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/default-value.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/default-value.schema/default/quicktype.hpp
index a470ca8..a8f5ccd 100644
--- a/base/schema-cplusplus/test/inputs/schema/default-value.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/default-value.schema/default/quicktype.hpp
@@ -55,6 +55,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("id") != j.end() && !j.at("id").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_id(j.at("id").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/id-no-address.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/id-no-address.schema/default/quicktype.hpp
index d2ea247..644cf29 100644
--- a/base/schema-cplusplus/test/inputs/schema/id-no-address.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/id-no-address.schema/default/quicktype.hpp
@@ -52,6 +52,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("item") != j.end() && !j.at("item").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_item(j.at("item").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/id-root.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/id-root.schema/default/quicktype.hpp
index 1418d0a..6df2398 100644
--- a/base/schema-cplusplus/test/inputs/schema/id-root.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/id-root.schema/default/quicktype.hpp
@@ -52,6 +52,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bar") != j.end() && !j.at("bar").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bar(j.at("bar").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/implicit-all-of.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/implicit-all-of.schema/default/quicktype.hpp
index 58819d0..bf5ce76 100644
--- a/base/schema-cplusplus/test/inputs/schema/implicit-all-of.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/implicit-all-of.schema/default/quicktype.hpp
@@ -62,6 +62,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("foo") != j.end() && !j.at("foo").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("foo").get<int64_t>());
         x.set_bar(j.at("bar").get<bool>());
         x.set_quux(j.at("quux").get<std::string>());
diff --git a/base/schema-cplusplus/test/inputs/schema/implicit-class-array-union.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/implicit-class-array-union.schema/default/quicktype.hpp
index bdd34cd..1c96681 100644
--- a/base/schema-cplusplus/test/inputs/schema/implicit-class-array-union.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/implicit-class-array-union.schema/default/quicktype.hpp
@@ -135,6 +135,7 @@ struct adl_serializer<std::variant<std::vector<int64_t>, bool, quicktype::FooCla
 namespace quicktype {
     inline void from_json(const json & j, FooClass& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bar") != j.end() && !j.at("bar").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bar(j.at("bar").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/implicit-one-of.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/implicit-one-of.schema/default/quicktype.hpp
index 1eaa20b..a70c403 100644
--- a/base/schema-cplusplus/test/inputs/schema/implicit-one-of.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/implicit-one-of.schema/default/quicktype.hpp
@@ -119,6 +119,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("foo") != j.end() && !j.at("foo").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("foo").get<int64_t>());
         x.set_bar(get_stack_optional<bool>(j, "bar"));
         x.set_quux(get_stack_optional<std::string>(j, "quux"));
diff --git a/base/schema-cplusplus/test/inputs/schema/integer-type.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/integer-type.schema/default/quicktype.hpp
index d35f43f..332015a 100644
--- a/base/schema-cplusplus/test/inputs/schema/integer-type.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/integer-type.schema/default/quicktype.hpp
@@ -240,14 +240,23 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("above_i32_max") != j.end() && !j.at("above_i32_max").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_above_i32_max(j.at("above_i32_max").get<int64_t>());
+        if (j.find("below_i32_min") != j.end() && !j.at("below_i32_min").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_below_i32_min(j.at("below_i32_min").get<int64_t>());
+        if (j.find("i32_range") != j.end() && !j.at("i32_range").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_i32_range(j.at("i32_range").get<int64_t>());
+        if (j.find("large_bounds") != j.end() && !j.at("large_bounds").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_large_bounds(j.at("large_bounds").get<int64_t>());
+        if (j.find("only_maximum") != j.end() && !j.at("only_maximum").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_only_maximum(j.at("only_maximum").get<int64_t>());
+        if (j.find("only_minimum") != j.end() && !j.at("only_minimum").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_only_minimum(j.at("only_minimum").get<int64_t>());
+        if (j.find("small_negative") != j.end() && !j.at("small_negative").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_small_negative(j.at("small_negative").get<int64_t>());
+        if (j.find("small_positive") != j.end() && !j.at("small_positive").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_small_positive(j.at("small_positive").get<int64_t>());
+        if (j.find("unbounded") != j.end() && !j.at("unbounded").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_unbounded(j.at("unbounded").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/minmax-integer.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/minmax-integer.schema/default/quicktype.hpp
index 8830777..3abb669 100644
--- a/base/schema-cplusplus/test/inputs/schema/minmax-integer.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/minmax-integer.schema/default/quicktype.hpp
@@ -231,13 +231,21 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("free") != j.end() && !j.at("free").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_free(j.at("free").get<int64_t>());
+        if (j.find("intersection") != j.end() && !j.at("intersection").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_intersection(j.at("intersection").get<int64_t>());
+        if (j.find("max") != j.end() && !j.at("max").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_max(j.at("max").get<int64_t>());
+        if (j.find("min") != j.end() && !j.at("min").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_min(j.at("min").get<int64_t>());
+        if (j.find("minmax") != j.end() && !j.at("minmax").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_minmax(j.at("minmax").get<int64_t>());
+        if (j.find("minMaxIntersection") != j.end() && !j.at("minMaxIntersection").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_min_max_intersection(j.at("minMaxIntersection").get<int64_t>());
+        if (j.find("minMaxUnion") != j.end() && !j.at("minMaxUnion").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_min_max_union(j.at("minMaxUnion").get<int64_t>());
+        if (j.find("union") != j.end() && !j.at("union").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_top_level_union(j.at("union").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/non-standard-ref.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/non-standard-ref.schema/default/quicktype.hpp
index 53875d6..2caf563 100644
--- a/base/schema-cplusplus/test/inputs/schema/non-standard-ref.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/non-standard-ref.schema/default/quicktype.hpp
@@ -62,7 +62,9 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("bar") != j.end() && !j.at("bar").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_bar(j.at("bar").get<int64_t>());
+        if (j.find("foo") != j.end() && !j.at("foo").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("foo").get<int64_t>());
         x.set_quux(j.at("quux").get<bool>());
     }
diff --git a/base/schema-cplusplus/test/inputs/schema/optional-const-ref.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/optional-const-ref.schema/default/quicktype.hpp
index 4667918..fd6650c 100644
--- a/base/schema-cplusplus/test/inputs/schema/optional-const-ref.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/optional-const-ref.schema/default/quicktype.hpp
@@ -316,9 +316,11 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_coordinates(get_stack_optional<std::vector<Coordinate>>(j, "coordinates"));
+        if (j.find("count") != j.end() && !j.at("count").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_count(get_stack_optional<int64_t>(j, "count"));
         x.set_label(get_stack_optional<std::string>(j, "label"));
         x.set_required_coordinates(j.at("requiredCoordinates").get<std::vector<Coordinate>>());
+        if (j.find("requiredCount") != j.end() && !j.at("requiredCount").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_required_count(j.at("requiredCount").get<int64_t>());
         x.set_required_label(j.at("requiredLabel").get<std::string>());
         x.set_weight(get_stack_optional<double>(j, "weight"));
diff --git a/base/schema-cplusplus/test/inputs/schema/optional-constraints.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/optional-constraints.schema/default/quicktype.hpp
index 0226922..6fbdd08 100644
--- a/base/schema-cplusplus/test/inputs/schema/optional-constraints.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/optional-constraints.schema/default/quicktype.hpp
@@ -272,9 +272,11 @@ namespace quicktype {
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
         x.set_opt_double(get_stack_optional<double>(j, "optDouble"));
+        if (j.find("optInt") != j.end() && !j.at("optInt").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_opt_int(get_stack_optional<int64_t>(j, "optInt"));
         x.set_opt_pattern(get_stack_optional<std::string>(j, "optPattern"));
         x.set_opt_string(get_stack_optional<std::string>(j, "optString"));
+        if (j.find("reqZeroMin") != j.end() && !j.at("reqZeroMin").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_req_zero_min(j.at("reqZeroMin").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/ref-id-files.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/ref-id-files.schema/default/quicktype.hpp
index dcbf488..94e8cb7 100644
--- a/base/schema-cplusplus/test/inputs/schema/ref-id-files.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/ref-id-files.schema/default/quicktype.hpp
@@ -52,6 +52,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("foo") != j.end() && !j.at("foo").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("foo").get<int64_t>());
     }
 
diff --git a/base/schema-cplusplus/test/inputs/schema/required-non-properties.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/required-non-properties.schema/default/quicktype.hpp
index 80688f0..37d6c53 100644
--- a/base/schema-cplusplus/test/inputs/schema/required-non-properties.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/required-non-properties.schema/default/quicktype.hpp
@@ -57,6 +57,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevel& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("foo") != j.end() && !j.at("foo").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_foo(j.at("foo").get<int64_t>());
         x.set_bar(get_untyped(j, "bar"));
     }
diff --git a/base/schema-cplusplus/test/inputs/schema/union.schema/default/quicktype.hpp b/head/schema-cplusplus/test/inputs/schema/union.schema/default/quicktype.hpp
index 087c0cc..8a2507d 100644
--- a/base/schema-cplusplus/test/inputs/schema/union.schema/default/quicktype.hpp
+++ b/head/schema-cplusplus/test/inputs/schema/union.schema/default/quicktype.hpp
@@ -121,6 +121,7 @@ namespace quicktype {
 
     inline void from_json(const json & j, TopLevelElement& x) {
         if (!j.is_object()) throw std::runtime_error("Expected object");
+        if (j.find("one") != j.end() && !j.at("one").is_number_integer()) throw std::runtime_error("Expected integer");
         x.set_one(get_stack_optional<int64_t>(j, "one"));
         x.set_two(j.at("two").get<bool>());
         x.set_three(get_stack_optional<double>(j, "three"));
