Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
7079e88d
Kaydet (Commit)
7079e88d
authored
May 18, 2015
tarafından
Stephan Bergmann
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
idlc: fix warnings
Change-Id: I2ef51fae0bc4425c5d2b6707d1df381888b427e7
üst
79533f3f
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
37 deletions
+24
-37
astoperation.hxx
idlc/inc/idlc/astoperation.hxx
+2
-2
astsequence.hxx
idlc/inc/idlc/astsequence.hxx
+3
-3
parser.y
idlc/source/parser.y
+14
-27
scanner.l
idlc/source/scanner.l
+5
-5
No files found.
idlc/inc/idlc/astoperation.hxx
Dosyayı görüntüle @
7079e88d
...
...
@@ -30,7 +30,7 @@ class AstOperation : public AstDeclaration
,
public
AstScope
{
public
:
AstOperation
(
AstType
*
pReturnType
,
const
OString
&
name
,
AstScope
*
pScope
)
AstOperation
(
AstType
const
*
pReturnType
,
const
OString
&
name
,
AstScope
*
pScope
)
:
AstDeclaration
(
NT_operation
,
name
,
pScope
)
,
AstScope
(
NT_operation
)
,
m_pReturnType
(
pReturnType
)
...
...
@@ -52,7 +52,7 @@ public:
// scope management
virtual
AstDeclaration
*
addDeclaration
(
AstDeclaration
*
pDecl
)
SAL_OVERRIDE
;
private
:
AstType
*
m_pReturnType
;
AstType
const
*
m_pReturnType
;
DeclList
m_exceptions
;
};
...
...
idlc/inc/idlc/astsequence.hxx
Dosyayı görüntüle @
7079e88d
...
...
@@ -24,7 +24,7 @@
class
AstSequence
:
public
AstType
{
public
:
AstSequence
(
AstType
*
pMemberType
,
AstScope
*
pScope
)
AstSequence
(
AstType
const
*
pMemberType
,
AstScope
*
pScope
)
:
AstType
(
NT_sequence
,
OString
(
"[]"
)
+
pMemberType
->
getScopedName
(),
pScope
)
,
m_pMemberType
(
pMemberType
)
,
m_pRelativName
(
NULL
)
...
...
@@ -35,7 +35,7 @@ public:
delete
m_pRelativName
;
}
AstType
*
getMemberType
()
const
AstType
const
*
getMemberType
()
const
{
return
m_pMemberType
;
}
virtual
bool
isUnsigned
()
const
SAL_OVERRIDE
...
...
@@ -43,7 +43,7 @@ public:
virtual
const
sal_Char
*
getRelativName
()
const
SAL_OVERRIDE
;
private
:
AstType
*
m_pMemberType
;
AstType
const
*
m_pMemberType
;
mutable
OString
*
m_pRelativName
;
};
...
...
idlc/source/parser.y
Dosyayı görüntüle @
7079e88d
...
...
@@ -332,7 +332,7 @@ bool includes(AstDeclaration const * type1, AstDeclaration const * type2) {
%type <exval> expression const_expr or_expr xor_expr and_expr
%type <exval> add_expr mult_expr unary_expr primary_expr shift_expr
%type <exval> literal
positive_int_expr
%type <exval> literal
%type <fdval> declarator
%type <dlval> declarators at_least_one_declarator
...
...
@@ -464,7 +464,7 @@ module_dcl :
}
}
delete(pModule);
pModule =
(AstModule*)pExists
;
pModule =
static_cast<AstModule*>(pExists)
;
} else
{
pScope->addDeclaration(pModule);
...
...
@@ -573,7 +573,7 @@ interface_dcl :
*/
if (pDecl->getNodeType() == NT_interface)
{
pForward =
(AstInterface*)pDecl
;
pForward =
static_cast<AstInterface*>(pDecl)
;
if ( !pForward->isDefined() )
{
/*
...
...
@@ -946,7 +946,7 @@ operation :
*/
if ( pScope && $1 )
{
AstType
*pType = (AstType*)$1
;
AstType
const *pType = static_cast<AstType const *>($1)
;
if ( !pType || (pType->getNodeType() == NT_exception) )
{
// type ERROR
...
...
@@ -990,7 +990,7 @@ operation :
*/
if ( pScope && pScope->getScopeNodeType() == NT_operation)
{
pOp =
(AstOperation*)pScope
;
pOp =
static_cast<AstOperation*>(pScope)
;
if ( pOp )
pOp->setExceptions($11);
...
...
@@ -1288,7 +1288,7 @@ constants_dcl :
{
pExists->setInMainfile(idlc()->isInMainFile());
delete(pConstants);
pConstants =
(AstConstants*)pExists
;
pConstants =
static_cast<AstConstants*>(pExists)
;
} else
{
pScope->addDeclaration(pConstants);
...
...
@@ -1434,19 +1434,6 @@ literal :
}
;
positive_int_expr :
const_expr
{
$1->evaluate(EK_const);
if ( !$1->coerce(ET_ulong) )
{
ErrorHandler::coercionError($1, ET_ulong);
delete $1;
$$ = NULL;
}
}
;
const_type :
integer_type
| byte_type
...
...
@@ -1652,7 +1639,7 @@ service_export :
if ( ErrorHandler::checkPublished(pDecl, bOptional) )
{
pIMember = new AstInterfaceMember(
$1,
(AstInterface*)pDecl
, *iter, pScope);
$1,
static_cast<AstInterface*>(pDecl)
, *iter, pScope);
pScope->addDeclaration(pIMember);
}
} else
...
...
@@ -1694,7 +1681,7 @@ service_export :
else if ( ErrorHandler::checkPublished(pDecl) )
{
pSMember = new AstServiceMember(
$1,
(AstService*)pDecl
, *iter, pScope);
$1,
static_cast<AstService*>(pDecl)
, *iter, pScope);
pScope->addDeclaration(pSMember);
}
} else
...
...
@@ -1735,7 +1722,7 @@ service_export :
pDecl = pScope->lookupByName(*iter);
if ( pDecl && (pDecl->getNodeType() == NT_interface) )
{
pObserves = new AstObserves(
(AstInterface*)pDecl
, *iter, pScope);
pObserves = new AstObserves(
static_cast<AstInterface*>(pDecl)
, *iter, pScope);
pScope->addDeclaration(pObserves);
} else
{
...
...
@@ -1776,7 +1763,7 @@ service_export :
pDecl = pScope->lookupByName(*iter);
if ( pDecl && (pDecl->getNodeType() == NT_service) )
{
pNeeds = new AstNeeds(
(AstService*)pDecl
, *iter, pScope);
pNeeds = new AstNeeds(
static_cast<AstService*>(pDecl)
, *iter, pScope);
pScope->addDeclaration(pNeeds);
} else
{
...
...
@@ -2405,7 +2392,7 @@ sequence_type_spec :
if ( $5 )
{
AstType
*pType = (AstType*)$5
;
AstType
const *pType = static_cast<AstType const *>($5)
;
if ( pType )
{
pSeq = new AstSequence(pType, pScope);
...
...
@@ -2672,7 +2659,7 @@ enum_type :
$$ = NULL;
else
{
$$ =
(AstEnum*)idlc()->scopes()->topNonNull(
);
$$ =
static_cast<AstEnum*>(idlc()->scopes()->topNonNull()
);
idlc()->scopes()->pop();
}
}
...
...
@@ -2706,7 +2693,7 @@ enumerator :
if ( pScope && pScope->getScopeNodeType() == NT_enum)
{
pEnum =
(AstEnum*)pScope
;
pEnum =
static_cast<AstEnum*>(pScope)
;
if (pEnum && $1)
{
AstExpression* pExpr = new AstExpression(pEnum->getEnumValueCount());
...
...
@@ -2735,7 +2722,7 @@ enumerator :
$3->evaluate(EK_const);
if ( $3->coerce(ET_long) )
{
pEnum =
(AstEnum*)pScope
;
pEnum =
static_cast<AstEnum*>(pScope)
;
if (pEnum)
{
pEnumVal = new AstConstant(ET_long , NT_enum_val,
...
...
idlc/source/scanner.l
Dosyayı görüntüle @
7079e88d
...
...
@@ -105,7 +105,7 @@ static int asciiToInteger(char const * s, sal_Int64 * sval, sal_uInt64 * uval)
// std::numeric_limits<sal_uInt64>::max() == SAL_MAX_UINT64:
sal_uInt64 nval = val * base + n;
if (nval < val) {
idlc()->error()->
syntaxError(
ErrorHandler::
syntaxError(
PS_NoState, idlc()->getLineNumber(),
"integral constant too large");
val = 0;
...
...
@@ -120,7 +120,7 @@ static int asciiToInteger(char const * s, sal_Int64 * sval, sal_uInt64 * uval)
} else if (val == SAL_CONST_UINT64(0x8000000000000000)) {
*sval = SAL_MIN_INT64;
} else {
idlc()->error()->
syntaxError(
ErrorHandler::
syntaxError(
PS_NoState, idlc()->getLineNumber(),
"negative integral constant too large");
*sval = 0;
...
...
@@ -233,7 +233,7 @@ static void parseLineAndFile(sal_Char* pBuf)
else
idlc()->setFileName(::rtl::OString(h));
bIsInMain =
(idlc()->getFileName() == idlc()->getRealFileName()) ? sal_True : sal_False
;
bIsInMain =
idlc()->getFileName() == idlc()->getRealFileName()
;
idlc()->setInMainfile(bIsInMain);
}
...
...
@@ -439,7 +439,7 @@ published return IDL_PUBLISHED;
{
if ( 0 != nIndex &&
(docu.getStr()[nIndex - 1] != '"' && docu.getStr()[nIndex - 1] != ':') )
idlc()->error()->
syntaxError(PS_NoState, idlc()->getLineNumber(),
ErrorHandler::
syntaxError(PS_NoState, idlc()->getLineNumber(),
"nested documentation strings are not allowed!");
}
idlc()->setDocumentation(docu);
...
...
@@ -456,7 +456,7 @@ published return IDL_PUBLISHED;
{
if ( 0 != nIndex &&
(docu.getStr()[nIndex - 1] != '"' && docu.getStr()[nIndex - 1] != ':') )
idlc()->error()->
syntaxError(PS_NoState, idlc()->getLineNumber(),
ErrorHandler::
syntaxError(PS_NoState, idlc()->getLineNumber(),
"nested documentation strings are not allowed!");
}
idlc()->setDocumentation(docu);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment