简体   繁体   English

如何在C ++ Builder中使用Delphi Inc()和Dec()过程

[英]How to use Delphi Inc() and Dec() procedures in C++ Builder

I'm a newbie programmer. 我是新手程序员。 I need to use Delphi's Inc() and Dec() procedures in C++ Builder XE like this: 我需要在C ++ Builder XE中使用Delphi的Inc()Dec()过程,如下所示:

Inc(Filler);

Dec(GridClientWidth);

Anyone can help me how to do this? 任何人都可以帮我怎么做?

You are looking for the ++ and -- operators : 您正在寻找++-- 运算符

Filler++;
GridClientWidth--;

In C++ these operators are baked into the language. 在C ++中,这些运算符被融入到语言中。 In Delphi, Inc and Dec are implemented as intrinsic routines . 在Delphi中, IncDec被实现为内部例程

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM