From 9542bb112419d575190a72baf7f964c3e32df223 Mon Sep 17 00:00:00 2001 From: "Kartik K. Agaram" Date: Sat, 25 Jul 2015 22:15:51 -0700 Subject: 1853 --- html/001help.cc.html | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) (limited to 'html/001help.cc.html') diff --git a/html/001help.cc.html b/html/001help.cc.html index 052fd061..2a89daac 100644 --- a/html/001help.cc.html +++ b/html/001help.cc.html @@ -14,12 +14,13 @@ pre { white-space: pre-wrap; font-family: monospace; color: #eeeeee; background- body { font-family: monospace; color: #eeeeee; background-color: #080808; } * { font-size: 1.05em; } .cSpecial { color: #008000; } +.SalientComment { color: #00ffff; } .Constant { color: #00a0a0; } +.PreProc { color: #c000c0; } +.Normal { color: #eeeeee; background-color: #080808; padding-bottom: 1px; } .Comment { color: #9090ff; } .Delimiter { color: #a04060; } -.SalientComment { color: #00ffff; } .Identifier { color: #804000; } -.PreProc { color: #c000c0; } --> @@ -35,7 +36,7 @@ body { font-family: monospace; color: #eeeeee; background-color: #080808; } //: This should give you a sense for what to look forward to in later layers. :(before "End Commandline Parsing") -if (argc <= 1 || is_equal(argv[1], "--help")) { +if (argc <= 1 || is_equal(argv[1], "--help")) { // this is the functionality later layers will provide // currently no automated tests for commandline arg parsing cerr << "To load files and run 'main':\n" @@ -58,7 +59,7 @@ if (argc <= 1 || //: way, our makefile contains a little command to automatically generate //: declarations for them. :(code) -bool is_equal(char* s, const char* lit) { +bool is_equal(char* s, const char* lit) { return strncmp(s, lit, strlen(lit)) == 0; } @@ -111,7 +112,7 @@ bool is_equal(char* s,// yadda-yadda. Instead use this macro below to perform an unsafe cast to // signed. We'll just give up immediately if a container's every too large. :(before "End Includes") -#define SIZE(X) (assert(X.size() < (1LL<<62)), static_cast<long long int>(X.size())) +#define SIZE(X) (assert(X.size() < (1LL<<(sizeof(long long int)*8-2))), static_cast<long long int>(X.size())) // // 5. Integer overflow is still impossible to guard against. Maybe after // reading http://www.cs.utah.edu/~regehr/papers/overflow12.pdf @@ -120,16 +121,16 @@ bool is_equal(char* s,#include<assert.h> #include<iostream> -using std::istream; -using std::ostream; -using std::iostream; -using std::cin; -using std::cout; -using std::cerr; +using std::istream; +using std::ostream; +using std::iostream; +using std::cin; +using std::cout; +using std::cerr; #include<cstring> #include<string> -using std::string; +using std::string; -- cgit 1.4.1-2-gfad0