Vuo
2.4.4
Loading...
Searching...
No Matches
compiler
VuoCompilerException.cc
Go to the documentation of this file.
1
10
#include "
VuoCompilerException.hh
"
11
#include "
VuoCompilerIssue.hh
"
12
16
VuoCompilerException::VuoCompilerException
(
const
VuoCompilerIssue
&issue)
17
:
VuoException
(issue.getShortDescription(false), false)
18
{
19
issues =
new
VuoCompilerIssues
(issue);
20
ownsIssues =
true
;
21
shortDescription = issues ? strdup(issues->
getShortDescription
(
false
).c_str()) :
nullptr
;
22
}
23
30
VuoCompilerException::VuoCompilerException
(
VuoCompilerIssues
*issues,
bool
ownsIssues)
31
:
VuoException
(issues ? issues->getShortDescription(false) :
""
, false)
32
{
33
this->issues = issues;
34
this->ownsIssues = ownsIssues;
35
this->shortDescription = issues ? strdup(issues->
getShortDescription
(
false
).c_str()) :
nullptr
;
36
}
37
41
VuoCompilerException::VuoCompilerException
(
const
VuoCompilerException
&other)
42
:
VuoException
(other)
43
{
44
VUserLog
(
"This shouldn't be called. You may need to replace `throw e` with `throw`."
);
45
this->issues =
nullptr
;
46
this->ownsIssues =
false
;
47
this->shortDescription =
nullptr
;
48
}
49
53
VuoCompilerException::~VuoCompilerException
(
void
)
throw
()
54
{
55
if
(ownsIssues)
56
delete
issues;
57
free(shortDescription);
58
}
59
63
VuoCompilerIssues
*
VuoCompilerException::getIssues
(
void
)
const
64
{
65
return
issues;
66
}
67
71
const
char
*
VuoCompilerException::what
()
const
throw()
72
{
73
return
shortDescription;
74
}
Generated on Thu Nov 9 2023 16:59:29 for Vuo by
1.9.8