More strict error checking in parseSpecifier + simplified code.
authorPatrik Hagglund <patrik.h.hagglund@ericsson.com>
Fri, 30 Nov 2012 10:06:59 +0000 (10:06 +0000)
committerPatrik Hagglund <patrik.h.hagglund@ericsson.com>
Fri, 30 Nov 2012 10:06:59 +0000 (10:06 +0000)
commit58b45535495d20639849abf7a5605be5c8304b66
treed6904bb2527e461b069e5e2ca2810b69ae8ef1a0
parent66ea2f99867ffc8606737199e359516fd1cfc67c
More strict error checking in parseSpecifier + simplified code.

For example, don't allow empty strings to be passed to getInt.

Move asserts inside parseSpecifier. (One day we may want to pass parse
error messages to the user - from LLParser - instead of using asserts,
but keep the code simple until then. There have been an attempt to do
this. See r142288, which got reverted, and r142605.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168991 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/DataLayout.h
lib/VMCore/DataLayout.cpp