在把这个问题标记为“重复”之前,请听我说,因为我在这个问题上被困了好几个小时。我已经仔细研究了现有的问题,但没有找到任何解决办法。
我正在学习角,并从角9+和角材料开始。我试图通过阅读中的文档来实现一个简单的角度材料对话框。
我的代码紧跟示例代码,但我不明白为什么我仍然收到这些错误消息:
'mat-dialog-content' is not a known element.
'mat-dialog-actions' is not a known element.
这个对话框确实会显示出来,但是它看起来好像在对话框模板html中没有呈现任何角度的物质组件/指令。
我试图用MatrizCrea(n,m)使用MatrizLibera(v)去分配一个矩阵,但两个free()都告诉我,类型之间存在冲突。
我在几个源代码之后编写了这段代码,所以我不知道为什么会发生这个错误。
header.h
typedef struct Matriz {int n, m, **d;} Matriz;
Matriz MatrizCrea(int n, int m);
void MatrizLibera(Matriz v);
body.c
Matriz MatrizCrea(int n, int m) {
Matriz mat;
mat.n = n;
这是基本的单元-测试,用于我的StatusComponent,包含角材料组件<mat-幻灯片-切换>。由ngCli命令生成。
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { StatusComponent } from './status.component';
describe('StatusComponent', () => {
let component: StatusComponent;
let fi