首页 \ 问答 \ 签名后的C ++参数声明[重复](C++ arguments declaration after the signature [duplicate])

签名后的C ++参数声明[重复](C++ arguments declaration after the signature [duplicate])

这个问题在这里已有答案:

我知道在C / C ++中你声明了这样的函数参数:

type functionName(type arg1,type arg2 )
{
    ...code...
}

但是有一些地方,例如http://www.enderunix.org/docs/eng/daemon.php我在哪里看到一个函数也可以像这样声明

type functionName(arg1, arg2)
type arg1;
type arg2;
{
    ...code..
}

这是一个有效的声明吗? 我从来没有在任何C / C ++手册中看到过类似的东西,任何人都可以告诉我这是否正确,如果这种声明有效,有什么利弊,如果可能的话,请指点我的手册或文件这解释了这个。 谢谢


This question already has an answer here:

I know that in C/C++ you declare function arguments like this:

type functionName(type arg1,type arg2 )
{
    ...code...
}

However there are a few places, for example here http://www.enderunix.org/docs/eng/daemon.php Where I see that a function can also be declared like this

type functionName(arg1, arg2)
type arg1;
type arg2;
{
    ...code..
}

Is that a valid declaration? I've never seen anything like that in any C/C++ manual, can anyone tell me if this is correct, what are the pros and cons for this type of declaration if it is valid, and if possible point me to some manual or document that explains this. Thanks


原文:https://stackoverflow.com/questions/32659596
更新时间:2023-03-23 16:03

最满意答案

您需要设置overflow:auto并删除#main-content上的左边距

#main-content {
background: none;
overflow: auto;
padding-top: 5px;

}

这对我行得通。


You need to set overflow:auto and remove the left padding on #main-content

#main-content {
background: none;
overflow: auto;
padding-top: 5px;

}

That works for me.

相关问答

更多
  • WebKit现在(至少Chrome 12)支持渐变作为边框图像: -webkit-border-image: -webkit-gradient(linear, left top, left bottom, from(#00abeb), to(#fff), color-stop(0.5, #fff), color-stop(0.5, #66cc00)) 21 30 30 21 repeat repeat; Prooflink - http://www.webkit.org/blog/1424/css3-gr ...
  • style.css CSS规则正在制作边框 th,td { border: 1px solid; padding: 8px; } This CSS rule in your style.css is making the border th,td { border: 1px solid; padding: 8px; }
  • 由于选项卡,第一个角落被删除。 这是一个FIDDLE .tab-content { border-radius: 0 30px 30px 30px; -moz-border-radius: 0 30px 30px 30px; -webkit-border-radius: 0 30px 30px 30px; } First corner removed because of the tab. Here's a FIDDLE .tab-content { border-radius: 0 30 ...
  • 你可以用一个元素和几个伪元素来实现。 下面可以看到一个快速演示。 div { position: relative; height: 300px; width: 80%; margin: 30px; background: tomato; } div:before { content: ""; position: absolute; top: -2px; left: -30px; width: calc(100% + 60px); hei ...
  • 我为你扔了一些东西: http : //codepen.io/woestijnrog/pen/YyNdQe 。 我从头开始,所以你将不得不适应你可以使用的东西。 为了避免使用文字回流的诡计 box-shadow 和 text-shadow 它似乎证实了你的四条规则。 I threw something together for you: http://codepen.io/woestijnrog/pen/YyNdQe. I started from scratch so you will have t ...
  • CSS聚合将多个CSS文件组合在一起。 如果一个文件中存在语法错误,则它可能会影响与其聚合的所有其他文件。 浏览器可以忽略文件末尾的一些语法错误,例如缺少close}。 但是,当该文件与其他文件组合时,它就成了问题。 尝试在Visual Studio中打开每个css文件并检查错误。 CSS aggregation combines multiple CSS files together. If there is a syntax error in one file, it can affect all th ...
  • 使用您拥有的空间正确设置宽度。 边框也需要垂直和水平2px。 .a_column { width: 512px; float:left; } .a_block, .some_text{ width: 254px; float: left; word-wrap: break-word; } .a_block{ border: 1px solid green; } .some_text{ border: 1px solid red; } 我在这里工作 ...
  • 你必须在CSS中的标签上给出width和height 100% ,如下所示。 并给出一个min-height:100%的身体标签在CSS。 检查DEMO 。 在看到您的代码之后,您还必须为@keyframes添加供应商前缀。 那么只有你的动画才有效。 html { background-color: #00006E; height:100%; width:100%; -webkit-font-smoothing: antialiased; } body{ min-height: ...
  • 您需要设置overflow:auto并删除#main-content上的左边距 #main-content { background: none; overflow: auto; padding-top: 5px; } 这对我行得通。 You need to set overflow:auto and remove the left padding on #main-content #main-content { background: none; overflow: auto; padding-top: ...
  • 使用带有box-shadow的伪元素的解决方案: div { background: orange; width: 400px; height: 40px; margin-top: 100px; z-index: 1; position: relative; } div:after { content: ""; position: absolute; height: 100px; left: 0px; right: 0 ...

相关文章

更多

最新问答

更多
  • 您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
  • 将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
  • OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
  • 页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
  • codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
  • 在计算机拍照在哪里进入
  • 使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
  • No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
  • 单页应用程序:页面重新加载(Single Page Application: page reload)
  • 在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
  • System.StackOverflow错误(System.StackOverflow error)
  • KnockoutJS未在嵌套模板上应用beforeRemove和afterAdd(KnockoutJS not applying beforeRemove and afterAdd on nested templates)
  • 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
  • android - 如何避免使用Samsung RFS文件系统延迟/冻结?(android - how to avoid lag/freezes with Samsung RFS filesystem?)
  • TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
  • 企业安全培训的各项内容
  • 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
  • C#类名中允许哪些字符?(What characters are allowed in C# class name?)
  • NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
  • 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
  • 将多个行和可变行移动到列(moving multiple and variable rows to columns)
  • 提交表单时忽略基础href,而不使用Javascript(ignore base href when submitting form, without using Javascript)
  • 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
  • Angular $资源不会改变方法(Angular $resource doesn't change method)
  • 在Angular 5中不是一个函数(is not a function in Angular 5)
  • 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
  • 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
  • 常见的python rpc和cli接口(Common python rpc and cli interface)
  • Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
  • 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)