静态语义的含义是什么? [英] Static Semantics meaning?

查看:494
本文介绍了静态语义的含义是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

术语静态语义学在编程中是什么意思?

What does term "static semantics" mean in programming?

静态语义学,语义学和动态语义学之间是什么关系?

What is relationship between static semantics, semantics and dynamic semantics?

我知道语义代表检查书面代码(无语法错误)是否具有任何含义。

I know that semantics stands for checking if written code (without syntax errors) has any meaning.

推荐答案

语义与意义有关。它包括:

Semantics is about meaning. It includes:


  • 静态语义,这是可以在编译时确定的部分,包括数据类型,是否全部声明变量,在作用域的情况下该声明适用于哪个变量,变量的类型,是否以正确的调用顺序调用函数和方法,赋值是否与类型兼容等,以及

  • the static semantics, which is the part that can be ascertained at compile time, including data typing, whether all variable are declared, which declaration applies to which variable in the case of scoping, what their type is, whether functions and methods are called with correct calling sequences, whether assignments are type-compatible, etc., and

动态语义,这是程序执行时实际发生的事情。

dynamic semantics, which is what actually happens when the program is executed.

这篇关于静态语义的含义是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆