问答文章1 问答文章501 问答文章1001 问答文章1501 问答文章2001 问答文章2501 问答文章3001 问答文章3501 问答文章4001 问答文章4501 问答文章5001 问答文章5501 问答文章6001 问答文章6501 问答文章7001 问答文章7501 问答文章8001 问答文章8501 问答文章9001 问答文章9501

请教fortran语言命令entry

发布网友 发布时间:2022-04-13 06:33

我来回答

1个回答

热心网友 时间:2022-04-13 08:03

够详细吧?
ENTRY
Statement: Provides one or more entry points within a subprogram. It is not executable and must precede any CONTAINS statement (if any) within the subprogram.

Syntax

ENTRY name [ ( [d-arg [, d-arg ] ...] ) [RESULT (r-name)] ]

name
Is the name of an entry point. If RESULT is specified, this entry name must not appear in any specification statement in the scoping unit of the function subprogram.

d-arg
(Optional) Is a mmy argument. The mmy argument can be an alternate return indicator (*) if the ENTRY statement is within a subroutine subprogram.

r-name
(Optional) Is the name of a function result. This name must not be the same as the name of the entry point, or the name of any other function or function result. This parameter can only be specified for function subprograms.
Rules and Behavior

ENTRY statements can only appear in external proceres or mole proceres.

An ENTRY statement must not appear in a CASE, DO, IF, FORALL, or WHERE construct, or a nonblock DO loop.

When the ENTRY statement appears in a subroutine subprogram, it is referenced by a CALL statement. When the ENTRY statement appears in a function subprogram, it is referenced by a function reference.

An entry name within a function subprogram can appear in a type declaration statement.

Within the subprogram containing the ENTRY statement, the entry name must not appear as a mmy argument in the FUNCTION or SUBROUTINE statement, and it must not appear in an EXTERNAL or INTRINSIC statement. For example, neither of the following are valid:

(1) SUBROUTINE SUB(E)
ENTRY E
...

(2) SUBROUTINE SUB
EXTERNAL E
ENTRY E
...

An ENTRY statement can reference itself if the function or subroutine subprogram was defined as RECURSIVE.

Dummy arguments can be used in ENTRY statements even if they differ in order, number, type and kind parameters, and name from the mmy arguments used in the FUNCTION, SUBROUTINE, and other ENTRY statements in the same subprogram. However, each reference to a function, subroutine, or entry must use an actual argument list that agrees in order, number, and type with the mmy argument list in the corresponding FUNCTION, SUBROUTINE, or ENTRY statement.

Dummy arguments can be referred to only in executable statements that follow the first SUBROUTINE, FUNCTION, or ENTRY statement in which the mmy argument is specified. If a mmy argument is not currently associated with an actual argument, the mmy argument is undefined and cannot be referenced. Arguments do not retain their association from one reference of a subprogram to another.

Compatibility

CONSOLE STANDARD GRAPHICS QUICKWIN GRAPHICS WINDOWS DLL LIB

See Also: Program Units and Proceres, ENTRY Statements in Function Subprograms, ENTRY Statements in Subroutine Subprograms

Example

C This fragment writes a message indicating
C whether num is positive or negative
IF (num .GE. 0) THEN
CALL Sign
ELSE
CALL Negative
END IF
...
END

SUBROUTINE Sign
WRITE (*, *) 'It''s positive.'
RETURN
ENTRY Negative
WRITE (*, *) 'It''s negative.'
RETURN
END SUBROUTINE

【 在 gaowj (john) 的大作中提到: 】
: 树上仅仅是简单的查到:
: 为子例程子程序和函数提更第二个入口
: 一般形式为:
: ...................
声明声明:本网页内容为用户发布,旨在传播知识,不代表本网认同其观点,若有侵权等问题请及时与本网联系,我们将在第一时间删除处理。E-MAIL:11247931@qq.com
养胃的药最好的是什么啊 婴儿积食发烧不愿吃药怎么办 板门穴位在哪个部位 手机设置放偷看的方法? 凝结水回收器生产厂家? 个人账户养老金预测公式:现有5万元,缴费20年,能领多少钱? 临沂比较有名的男装品牌 呼伦贝尔市悦动网络科技有限公司怎么样? 呼伦贝尔中汇实业有限公司怎么样? 呼伦贝尔油玉不绝电子商务有限公司怎么样? 《初中生活因梦想而美丽》 作文600字 我用vc++6.0里边出现error spawing c1.exe是什么意思? 梦想刷新了我的生活 600字以上作文 孕妇冬天怎样吃水果好 孕妇冬天如何吃水果 要如何清洗3p空调蒸发器?有没有什么快捷的方法? 冬天适合孕妇吃的水果 冬天孕妇怎么吃水果 清洗空调蒸发器的方法谁能教教我?过程怎么样 办公室买打印机,买什么型号好 冬季孕妇的水果怎么吃? 岳阳乘车码可在长沙使用吗? 冬天太冷孕妇怎么吃水果 请问你的etc问题解决了吗?我也出现了同样的问题,etc绑定的银行卡号注销了,没法还欠的钱,谢谢哦 etc欠费注销后才发现有欠费 急求“约翰.肯尼迪 政教要绝对分离”的英文演讲稿 行政诉讼庭审后法院把假的证据拿来给我不会犯法吗? 行政诉讼模拟期末考试判决书怎么写?需要注意哪些问题? 急寻!行政诉讼案件 较详细的庭审记录! 行政诉讼中应该如何质证 低筋面粉需要烫吗 煮好的南瓜隔夜可以吃吗 蒸的南瓜隔夜还能吃吗 新人求助,steam的个人资料打不开怎么办 Steam的社区和个人账号打不开了怎么办=.= 蒸好的南瓜可以隔夜吃吗 steam账号社区和个人打不开,显示错误代码103怎么办,在哪都打不开! steam打不开社区和个人资料 steam为什么创建创建新账户就进不去了 辣椒包肉馅外焦皮的做法 网上买台笔记本电脑一般多少天能到货 淘宝网买笔记本电脑至少几天可以得到? 官网订购笔记本多久能到货? 在联想官网买笔记本电脑,下单付款之后通常几天能到?他们用的什么快递? 请问我在京东上面买了一个笔记本电脑商家审核成功了是银行卡支付的要多久才能到我卡里要三天吗能不能快? 天猫商城买笔记本电脑一般多久才能收到? 我在淘宝买了个笔记本电脑24号晚上从深圳发货昨天凌晨4点到广州集散中心,还需要多久能到青岛,是顺丰速递 我爸花了3500让我哥上淘宝给我买华硕的笔记本电脑,然后我要等多久才可以到账? 我在京东上买了一部笔记本电脑,因为工作需要有点急,是成都运过来的,要多久才能到云南。 顺丰快递深圳到上海要多久? 我在网上买了台笔记本电脑,据说顺丰快递深圳到上海第二天就能到,可又听说